search for: some_funct

Displaying 20 results from an estimated 25 matches for "some_funct".

Did you mean: some_func
2013 Mar 01
1
.Call interface: Use R SEXP as C mutable *char
Dear R Developers, DISCLAIMER: I am new to package development in R and new to this list. I am trying to do something along the lines of: SEXP test_fun (SEXP filename) { const char *inputfile = translateChar(STRING_ELT(filename, 0)); int abc = some_function(inputfile); ... } The code compiles fine, but I get a warning: "passing argument of 'some_function' discards qualifiers from pointer target type" I read up on my issue and found this posting: https://stat.ethz.ch/pipermail/r-devel/2011-June/061221.html I gather that the &...
2012 Sep 25
0
[libopusfile PATCH] build: implement autotools build system for libopusfile. (v3)
...+ CC_CHECK_ATTRIBUTE( + [visibility_$1], [visibility("$1")], + [void __attribute__((visibility("$1"))) $1_function() { }], + [$2], [$3]) +]) + +AC_DEFUN([CC_ATTRIBUTE_NONNULL], [ + CC_CHECK_ATTRIBUTE( + [nonnull], [nonnull()], + [void __attribute__((nonnull())) some_function(void *foo, void *bar) { foo = (void*)0; bar = (void*)0; }], + [$1], [$2]) +]) + +AC_DEFUN([CC_ATTRIBUTE_UNUSED], [ + CC_CHECK_ATTRIBUTE( + [unused], , + [void some_function(void *foo, __attribute__((unused)) void *bar);], + [$1], [$2]) +]) + +AC_DEFUN([CC_ATTRIBUTE_SENTINEL], [ + C...
2012 Sep 25
3
[libopusfile PATCH] build: implement autotools build system for libopusfile. (v2)
...+ CC_CHECK_ATTRIBUTE( + [visibility_$1], [visibility("$1")], + [void __attribute__((visibility("$1"))) $1_function() { }], + [$2], [$3]) +]) + +AC_DEFUN([CC_ATTRIBUTE_NONNULL], [ + CC_CHECK_ATTRIBUTE( + [nonnull], [nonnull()], + [void __attribute__((nonnull())) some_function(void *foo, void *bar) { foo = (void*)0; bar = (void*)0; }], + [$1], [$2]) +]) + +AC_DEFUN([CC_ATTRIBUTE_UNUSED], [ + CC_CHECK_ATTRIBUTE( + [unused], , + [void some_function(void *foo, __attribute__((unused)) void *bar);], + [$1], [$2]) +]) + +AC_DEFUN([CC_ATTRIBUTE_SENTINEL], [ + C...
2010 Oct 01
3
scoping goes wrong when some functions are used within others.
...w.com, and couldn't but notice there are quite some questions popping up that deal with scoping in relation to custom functions. I grinded my teeth on it already, and I have absolutely no clue what goes wrong. The general pattern is as follows : ff <- function(x){ y <- some_value some_function(y) } > ff(x) Error in eval(expr, envir, enclos) : object 'y' not found I tried to report this as a bug earlier, but got the message I used the wrong channel. I also don't know how to formalize it into a bug report on the report site. That's why I bring it to your attention t...
2012 Sep 29
2
[libopusfile PATCH] build: implement autotools build system for libopusfile. (v4)
...+ CC_CHECK_ATTRIBUTE( + [visibility_$1], [visibility("$1")], + [void __attribute__((visibility("$1"))) $1_function() { }], + [$2], [$3]) +]) + +AC_DEFUN([CC_ATTRIBUTE_NONNULL], [ + CC_CHECK_ATTRIBUTE( + [nonnull], [nonnull()], + [void __attribute__((nonnull())) some_function(void *foo, void *bar) { foo = (void*)0; bar = (void*)0; }], + [$1], [$2]) +]) + +AC_DEFUN([CC_ATTRIBUTE_UNUSED], [ + CC_CHECK_ATTRIBUTE( + [unused], , + [void some_function(void *foo, __attribute__((unused)) void *bar);], + [$1], [$2]) +]) + +AC_DEFUN([CC_ATTRIBUTE_SENTINEL], [ +...
2009 Nov 01
5
Headache with sessions being shared.
I have a really horrendous problem with sessions. before_filter :find_cart_from_session private def find_cart_from_session if session[:cart] # if there''s is a cart in the session begin @cart = Cart.find(session[:cart]) # return existing or new cart rescue ActiveRecord::RecordNotFound @cart = Cart.create @cart.save session[:cart] = @cart.id
2011 Nov 20
1
place values into a matrix efficiently?
...value updates. I probably will never need to do this, but wanted to ask if there are efficient methods to perform the for-loop in the following sequence. %xymat<-matrix(rep(0,100) nr=10,nc=10) # empty matrix %x<-1:10 %y<-sample.int(10,10,rep=T) %for (j in 1:10) xymat[x[j],y[j]] <- some_function(x[j],y[j]) #to create either false-color or 3D map . plot(0:1,0:1,t='n') % rasterImage(xymat/max(xymat),0,0,1,1,interp=F) This will produce a raster image of the original data(x vs y) that looks like plot(x,y) . Anyway, I just seem to be blanking: is there some vectorized way to pla...
2016 Sep 12
2
Counterintuitive use of LLVMBool in C-API?
Hi, I stumbled across the following: > /* Builds a module from the bitcode in the specified memory buffer, > returning a > reference to the module via the OutModule parameter. Returns 0 on success. > */ > LLVMBool LLVMParseBitcode2(LLVMMemoryBufferRef MemBuf, > LLVMModuleRef *OutModule); However in most scenarios i know, a Bool is something like 0 = False !0 = True In short:
2016 Sep 12
1
Counterintuitive use of LLVMBool in C-API?
...rintuitive? > > It is counterintuitive, but it is also consistent with a lot of C APIs > (including most of the standard library). Returning 0 on success and > non-zero on failure is a very common idiom in C. The rationale is that you > can write: > > int ret; > if ((ret = some_function())) > // Error handling > > and that ret will contain a meaningful error code on return (the latter is > missing when you use a boolean type). > > David > > -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://lists.llvm.org/p...
2010 Jul 28
1
How to point a column of dataframe by a "character"
...t variable. That is, I first attach the data. I can type a to pull out values of data[,"a"] (a vector of numeric) directly. However, using Xs[1] will give me only "character" - "a". Thus, is there any function that allow me to pull values of dadta[,"a"] , eg, some_function(Xs[1]) give me values of data[,"a"] Any help is appreciated. Tony [[alternative HTML version deleted]]
2012 Jan 27
0
[LLVMdev] [RFC] Module Flags Metadata
...do with llvm-extract? llvm-extract already copies over named metadata. > Should it keep a copy of every global metadata node that references a function? What do you mean by this? MDNodes cannot have references to global values. Or do you mean something like: !0 = metadata !{ metadata !"some_function" } > The same applies to bugpoint. Yup! > What if the NamedMDNode is used in codegen, and removing it removes the crash? Then it's a bug and should be fixed. > Simply put, I don't like this design, but my objections are weak and I lack an alternative plan. :-( The on...
2008 Dec 17
3
Access from common class
Hello! I have made a common class and put it to the /lib folder of my Rails application. Now I have some problems with access to: 1. Mailers Call to SupportMailer.send_activation_email gives an error: NoMethodError (undefined method `send_activation_email'' for SupportMailer:Class): Ok, I have changed my SupportMailer class - give a prefix to the function function send_activation_email
2015 Nov 16
2
Best way to implement optional functions?
On 16/11/2015 4:00 AM, Richard Cotton wrote: > On 22 October 2015 at 22:55, Duncan Murdoch <murdoch.duncan at gmail.com> wrote: >> I'm planning on adding some new WebGL functionality to the rgl package, but >> it will pull in a very large number of dependencies. Since many people won't >> need it, I'd like to make the new parts optional. > >> Can
2008 Sep 30
12
dtrace missing ''unlinkat''? showing process stack?
everyone, Just out of curiosity, I did a dtrace -n ''syscall:::entry { @num[execname, probefunc] = count(); }'' and looked at the entries produced by ''rm''. I see everything that rm did, *except* the unlinkat - which is unfortunate because I want to trace which processes have deleted which files. So - does dtrace contain unlinkat as a probe for a system call?
2012 Jan 25
3
[LLVMdev] [RFC] Module Flags Metadata
Chandler Carruth wrote: > On Tue, Jan 24, 2012 at 12:02 PM, Bill Wendling <wendling at apple.com > <mailto:wendling at apple.com>> wrote: > > On Jan 24, 2012, at 1:35 AM, Chandler Carruth wrote: > > > On Wed, Jan 18, 2012 at 1:36 PM, Bill Wendling > <wendling at apple.com <mailto:wendling at apple.com>> wrote: > > Hello, >
2009 Mar 03
0
[LLVMdev] One way to support unwind on x86
...ve to do anything, since functions return and have registers restored in the usual way. > I want to tag all calls and invokes in a manner that can be easily > recognized by a runtime. I can tolerate a small overhead on calls. The > idea is to do something like this: > > call some_function > jmp continue > jmp case_of_unwinding > continue: This again looks a lot like the "have functions return an extra boolean" method. > The case-of-unwinding will either unwind the current call frame or > jump to the landing pad (if it was an invoke i...
2009 Mar 03
5
[LLVMdev] One way to support unwind on x86
...e moves needed to restore the registers of the previous call frame (the caller) and to remove the current frame. I want to tag all calls and invokes in a manner that can be easily recognized by a runtime. I can tolerate a small overhead on calls. The idea is to do something like this: call some_function jmp continue jmp case_of_unwinding continue: The case-of-unwinding will either unwind the current call frame or jump to the landing pad (if it was an invoke instruction). I think the overhead will in fact be quite small because of branch prediction on modern processors. The...
2005 Nov 25
2
Wx::SystemSettings mark II
hi patches and files for Wx::SystemSettings, with get_font included in swig file and a sample that doesn''t segfault wxruby. CVS patches: RubyConstants.i, type_map.i CVS new: system_settings.rb (sample) SystemSettings.i (SWIG file) The sample should allow you to view the available information about system colours, fonts and metrics (eg cursor size, display size) in a Grid.
2008 Nov 05
1
Constants in models are initialized before fixtures are loaded?
Hi, here''s simplified code from the model: class Foo < AR::Base FIRST = Foo.first.id end The problem is that when testing I get well known error: "Called id for nil...". I guess that this constant is initialized before the fixtures are loaded. Is there any way to fix it? --~--~---------~--~----~------------~-------~--~----~ You received this message because you are
2017 Sep 18
0
Counterintuitive use of LLVMBool in C-API?
...is counterintuitive, but it is also consistent with a lot of C APIs >> (including most of the standard library). Returning 0 on success and >> non-zero on failure is a very common idiom in C. The rationale is that you >> can write: >> >> int ret; >> if ((ret = some_function())) >> // Error handling >> >> and that ret will contain a meaningful error code on return (the latter >> is missing when you use a boolean type). >> >> David >> >> > -------------- next part -------------- An HTML attachment was scrubbe...