Hi Mauio,  
Using another parameter is ok if it solves things in a way that precludes 
wanting other synthetic parameters for each sort of Both that is of interest
e.g `( (size,digits), (size,bits), (bits, digits), (size, internal 
precision) ... (internal precision, digits) )`.  otoh, it is better to not 
assign to parameters
roles that compensate for something parameters are not yet available to do.

Do you know if v0.5 always allocates immutable types at (a) 64 bit aligned 
addresses, 
at (b) 64 byte aligned addresses when sizeof( immutable ) is >= 64 bytes 
and rem( sizeof(immutable), 64 ) == 0 holds,
at (c) 1Kbit aligned addresses under similar circumstances with larger 
immutable types?







On Tuesday, July 5, 2016 at 2:38:40 AM UTC-4, Mauro wrote:
>
> What about: 
>
> immutable fromClibWithCfinalizer{ sizeofThisType, digitsofSignificand, 
> Both } 
>   exponent ::NTuple{ Both, UInt32 ) 
>   ... 
> end 
>
> function fromClibWithCfinalizer( _ ) 
>   Both = fn( sizeofThisType, digitsOfSignificand ) 
>   fromClibWithCfinalizer{sizeofThisType, digitsOfSignificand, Both}(_) 
> end 
>
> This way you end up with one more parameter, but maybe ok? 
>
> On Mon, 2016-07-04 at 23:06, Jeffrey Sarnoff <[email protected] 
> <javascript:>> wrote: 
> > Are there styles/approaches/packages/practices that may make simple and 
> > untedious using Julia to generate and fill templated Julia source code? 
> > My use case is to complete facets of type declarations that require more 
> > symbiosis of parameters than Julia learned to do while in kindergarten. 
> > 
> > 
> > immutable fromClibWithCfinalizer{ sizeofThisType, digitsofSignificand } 
> >   exponent ::NTuple{ fn( sizeofThisType, digitsOfSignificand ), UInt32 ) 
> >   ... 
> >   function fromClibWithCfinalizer( _ ) ? end; 
> > end 
> > 
> > 
> > bitsReqdForDigits( digs ) = ceil(Int, digs*log(2, 10) ) 
> > 
> > fn( sizeofThisType, digitsOfSignifcand ) = 
> >   ( sizeofThisType - bitsReqdForDigits(digitsOfSignificand) 
> >      - stabilityBits - guardBits - 1 - reservedBits   ) 
> > 
> > 
> > 
> > advancing thanks 
>

Reply via email to