Lex, check out Tim's suggestion here 
<https://groups.google.com/d/msg/julia-users/GXH8UBFYd0U/iiuXZswbaJUJ>. I 
believe this can also be done with a let binding, but I can't seem to find 
the reference and my Julia is compiling so I can't rework the incantation 
atm. Thanks for documenting!

Jason

On Friday, January 2, 2015 4:54:51 PM UTC-6, [email protected] wrote:
>
> Am waiting for an answer to the question about a mutable version before 
> adding doc.
>
> Cheers
> Lex
>
> On Saturday, January 3, 2015 12:18:58 AM UTC+10, Tim Holy wrote:
>>
>> Adding documentation is a great way for users to contribute! See the 
>> CONTRIBUTING.md file if you're new to this. 
>>
>> --Tim 
>>
>> On Friday, January 02, 2015 04:56:05 AM [email protected] wrote: 
>> > And more generally, sections for C++ and java in Noteworthy Differences 
>> > <http://julia.readthedocs.org/en/latest/manual/noteworthy-differences/> 
>>
>> > would be useful. Except, I'm thinking of not only syntactic 
>> differences, 
>> > but rather how very common features or idioms in C++ are done in Julia. 
>> A 
>> > colleague asked if Julia supports objects. I said; yes, well not 
>> really, 
>> > but you do it like this. A section like that could quickly show whether 
>> you 
>> > can do what you want with Julia. 
>> > 
>> > On Thursday, January 1, 2015 2:23:39 AM UTC+1, Josh Langsfeld wrote: 
>> > > I currently am trying to solve a problem where I have many composite 
>> types 
>> > > and I would like to associate some data with each type, such that 
>> every 
>> > > instance has access to it. Obviously, in C++ I would just create a 
>> static 
>> > > member variable. 
>> > > 
>> > > Is there a good way to go about this in Julia? Currently, I have it 
>> > > working by using a global Dict mapping DataType objects to their 
>> > > associated 
>> > > data but I really don't like this. Something more naive like just 
>> adding 
>> > > that field to every object instance also strikes me as unnecessary 
>> and 
>> > > wasteful. I haven't seen any significant discussion about static 
>> fields on 
>> > > the lists or on github so is this something that could be considered 
>> for 
>> > > addition to the language? 
>> > > 
>> > > Thanks, 
>> > > Josh 
>>
>>

Reply via email to