Re: Recommendations on porting Python to D

2024-08-15 Thread Chris Piker via Digitalmars-d-learn
On Saturday, 10 August 2024 at 11:10:01 UTC, IchorDev wrote: Does any of this code happen to be open-source? The initial code I'd like to convert isn't open-source yet, though it will have to be soon. NASA is big on open source these days. The logic being, the public paid for development, s

Re: Why does this mixin fail to compile?

2024-08-15 Thread Stefan Koch via Digitalmars-d-learn
On Tuesday, 13 August 2024 at 19:40:30 UTC, IchorDev wrote: On Monday, 12 August 2024 at 15:23:31 UTC, Stefan Koch wrote: It's about 12.000 lines of code. I am not sure how much has rotted away, I last touched it in 2021. The relevant files would be: the bytecode interpreter: https://github.c

Re: create fixed length string of characters

2024-08-15 Thread Olivier Pisano via Digitalmars-d-learn
On Friday, 16 August 2024 at 06:15:18 UTC, Bruce wrote: Is there an easy way to create a 60 character string in D? Like in Python... ul = '-'*60 You can use the repeat() function in std.range to create a range of N consecutive elements. If you need to assign this range to a string, you'll have