[fpc-pascal]How to assign values to a record variable?
    Göran Andersson 
    guffa at guffa.com
       
    Fri Aug  2 01:51:45 CEST 2002
    
    
  
Of course it won't. Silly me. :/
It should be ordinary parenthesises.
I remember now exactly how I did it in TP. I simply made a typed constant,
then any variable of the same record type can be assigned the value of the
constant.
The only real difference from the C implementation is that you have to give
the value a name. I bet the final compiled code will look very similar...
/GreenGhost
>
> On Thu, 1 Aug 2002, Göran Andersson wrote:
>
> > I fI remember correctly, this worked in TP, at least:
> >
> > a={x:1;y:0};
>
> I'm quite sure that won't work, since { ... } is a comment :)
>
>
> Jonas
>
>
> _______________________________________________
> fpc-pascal maillist  -  fpc-pascal at lists.freepascal.org
> http://lists.freepascal.org/mailman/listinfo/fpc-pascal
>
    
    
More information about the fpc-pascal
mailing list