Updating to newer files with different disk formats

2020-12-15 Thread Joel via Digitalmars-d-learn
I found using timeLastModified from macOS drive to ExFat, macOS has higher precision than ExFat[0], so a different number. My little program lists the files to update, but I get files to update still, after updating them, because of the differences with the disk formats. [0] from time:

Re: C++ code to D (multi dem 3d mesh)

2020-10-27 Thread Joel via Digitalmars-d-learn
On Tuesday, 27 October 2020 at 08:14:28 UTC, Imperatorn wrote: On Tuesday, 27 October 2020 at 07:32:30 UTC, Joel wrote: On Tuesday, 27 October 2020 at 07:17:46 UTC, Imperatorn wrote: On Monday, 26 October 2020 at 23:38:22 UTC, Joel wrote: ``` struct vec3d { float x, y, z; } [...]

Re: C++ code to D (multi dem 3d mesh)

2020-10-27 Thread Joel via Digitalmars-d-learn
On Tuesday, 27 October 2020 at 07:17:46 UTC, Imperatorn wrote: On Monday, 26 October 2020 at 23:38:22 UTC, Joel wrote: ``` struct vec3d { float x, y, z; } [...] It's not really clear what your question is. I'm trying to convert from C++ code to D code, see where I've put '// This

Re: C++ code to D (multi dem 3d mesh)

2020-10-27 Thread Joel via Digitalmars-d-learn
On Monday, 26 October 2020 at 23:38:22 UTC, Joel wrote: ``` struct vec3d { float x, y, z; } struct triangle { vec3d[3] p; } struct mesh { triangle[] tris; } // This here meshCube.tris = { // SOUTH { 0.0f, 0.0f, 0.0f,0.0f, 1.0f, 0.0f,1.0f,

C++ code to D (multi dem 3d mesh)

2020-10-26 Thread Joel via Digitalmars-d-learn
``` struct vec3d { float x, y, z; } struct triangle { vec3d[3] p; } struct mesh { triangle[] tris; } // This here meshCube.tris = { // SOUTH { 0.0f, 0.0f, 0.0f,0.0f, 1.0f, 0.0f,1.0f, 1.0f, 0.0f }, { 0.0f, 0.0f,

Re: Linking lib files

2020-09-24 Thread Joel via Digitalmars-d-learn
On Saturday, 4 July 2020 at 01:15:03 UTC, Joel wrote: Using Windows 10. In my dub.json file I have: "lflags" : ["+..\\DAllegro5\\lib\\"], But I get: Linking... lld-link: error: could not open '+..\DAllegro5\lib\': no such file or directory lld-link: error: could not open 'allegro.lib': no

Re: Cannot call @system funciton (stdout)

2020-08-16 Thread Joel via Digitalmars-d-learn
On Sunday, 16 August 2020 at 18:13:07 UTC, Anonymouse wrote: On Sunday, 16 August 2020 at 10:07:02 UTC, Simen Kjærås wrote: On Saturday, 15 August 2020 at 23:59:36 UTC, Joel wrote: [...] First, what's wrong with using writeln and friends instead of directly mucking about with stdout? :p

Cannot call @system funciton (stdout)

2020-08-15 Thread Joel via Digitalmars-d-learn
../../JMiscLib/source/jmisc/base.d(176,2): Error: @safe function jmisc.base.upDateStatus!string.upDateStatus cannot call @system function std.stdio.makeGlobal!"core.stdc.stdio.stdout".makeGlobal /Library/D/dmd/src/phobos/std/stdio.d(4837,20):

Linking lib files

2020-07-03 Thread Joel via Digitalmars-d-learn
Using Windows 10. In my dub.json file I have: "lflags" : ["+..\\DAllegro5\\lib\\"], But I get: Linking... lld-link: error: could not open '+..\DAllegro5\lib\': no such file or directory lld-link: error: could not open 'allegro.lib': no such file or directory ... lld-link: error: could not

Re: unit test that show more than one failure

2020-06-16 Thread Joel via Digitalmars-d-learn
On Tuesday, 16 June 2020 at 07:39:20 UTC, Luis wrote: On Tuesday, 16 June 2020 at 06:19:51 UTC, Joel wrote: [...] I understand that where the trivial test code is placed, must be something more complex being tested. @("dummy test 1"); unittest { /// Some test code that runs fine }

unit test that show more than one failure

2020-06-16 Thread Joel via Digitalmars-d-learn
I've tired different unit test libraries, but they jump out on errors instead of just adding to failed numbers. I'm thinking like this: ``` @("dummy"); unittset { 0.shouldEqual(0); 1.shouldEqual(2); 2.shouldEqual(3); } ``` Test: dummy test passed line 10: 0 is equal to 0 test failed

Re: Compile and run programs off USB drive

2020-05-21 Thread Joel via Digitalmars-d-learn
On Thursday, 21 May 2020 at 06:23:10 UTC, Joel wrote: With Windows OS. How would I use my USB drive to compile and run (with 64-bit too)? So far I made a bat file that adds D to %PATH%. There's no zip file of DMD to download, and I didn't get the 7z to work (even with the 7z program?!) -

Re: link error on Windows

2020-05-21 Thread Joel via Digitalmars-d-learn
On Wednesday, 20 May 2020 at 09:31:38 UTC, Nathan S. wrote: On Tuesday, 19 May 2020 at 04:54:38 UTC, Joel wrote: I tried with DMD32 D Compiler v2.088.1-dirty, and it compiled and created an exe file, but not run (msvcr100.dll not found - and tried to find it on the net without success). DMD

Compile and run programs off USB drive

2020-05-21 Thread Joel via Digitalmars-d-learn
With Windows OS. How would I use my USB drive to compile and run (with 64-bit too)? So far I made a bat file that adds D to %PATH%. There's no zip file of DMD to download, and I didn't get the 7z to work (even with the 7z program?!) - last time I tried. With 64-bit, I don't see what to do

Re: link error on Windows

2020-05-18 Thread Joel via Digitalmars-d-learn
I tried with DMD32 D Compiler v2.088.1-dirty, and it compiled and created an exe file, but not run (msvcr100.dll not found - and tried to find it on the net without success).

link error on Windows

2020-05-17 Thread Joel via Digitalmars-d-learn
I think is works with older versions of DMD. D:\jpro\dpro2\SpellIt>dub Performing "debug" build using D:\jpro\dmd2\windows\bin\dmd.exe for x86_64. bindbc-loader 0.3.0: target for configuration "noBC" is up to date. bindbc-sdl 0.18.0: target for configuration "dynamic" is up to date. spellit

Re: What could this be?

2020-05-11 Thread Joel via Digitalmars-d-learn
On Monday, 11 May 2020 at 11:37:40 UTC, Simen Kjærås wrote: On Monday, 11 May 2020 at 11:20:51 UTC, Joel wrote: I'm gotten stuck with this error - "..is not visible from module.." Without some code it's hard to say exactly, but this generally means you're referencing a private symbol in a

What could this be?

2020-05-11 Thread Joel via Digitalmars-d-learn
I'm gotten stuck with this error - "..is not visible from module.."

Re: Running GtkD programs on macOS

2019-11-29 Thread Joel via Digitalmars-d-learn
On Friday, 29 November 2019 at 08:22:09 UTC, Joel wrote: I've used dub alright, but don't know how to install the dylib files: object.Exception@../../../../.dub/packages/gtk-d-3.9.0/gtk-d/generated/gtkd/gtkd/Loader.d(125): Library load failed (libatk-1.0.0.dylib): dlopen(libatk-1.0.0.dylib,

Running GtkD programs on macOS

2019-11-29 Thread Joel via Digitalmars-d-learn
I've used dub alright, but don't know how to install the dylib files: object.Exception@../../../../.dub/packages/gtk-d-3.9.0/gtk-d/generated/gtkd/gtkd/Loader.d(125): Library load failed (libatk-1.0.0.dylib): dlopen(libatk-1.0.0.dylib, 258): image not found What's a good way to fix this

Re: Parsing with dxml

2019-11-20 Thread Joel via Digitalmars-d-learn
On Wednesday, 20 November 2019 at 00:07:53 UTC, Joel wrote: On Tuesday, 19 November 2019 at 14:20:39 UTC, Kagamin wrote: On Monday, 18 November 2019 at 06:44:43 UTC, Joel wrote: ``` http://www.w3.org/2001/XMLSchema-instance;> ``` You're missing a closing tag. I can store the ASV

Re: Parsing with dxml

2019-11-19 Thread Joel via Digitalmars-d-learn
On Tuesday, 19 November 2019 at 14:20:39 UTC, Kagamin wrote: On Monday, 18 November 2019 at 06:44:43 UTC, Joel wrote: ``` http://www.w3.org/2001/XMLSchema-instance;> ``` You're missing a closing tag. I can store the ASV Bible in an array (I check for if the last book, chapter, and

Re: Parsing with dxml

2019-11-18 Thread Joel via Digitalmars-d-learn
On Tuesday, 19 November 2019 at 04:43:31 UTC, Joel wrote: On Tuesday, 19 November 2019 at 02:45:29 UTC, Jonathan M Davis wrote: [...] Thanks for taking the time to reply. I have had another xml Bible version text in the past [1]. It had a different format. And Adam Ruppe helped me by

Re: Parsing with dxml

2019-11-18 Thread Joel via Digitalmars-d-learn
On Tuesday, 19 November 2019 at 02:45:29 UTC, Jonathan M Davis wrote: On Sunday, November 17, 2019 11:44:43 PM MST Joel via Digitalmars-d-learn wrote: [...] You need to be checking the type of the entity before you call either name or text on it, because not all entities have a name

Re: Parsing with dxml

2019-11-18 Thread Joel via Digitalmars-d-learn
On Monday, 18 November 2019 at 06:44:43 UTC, Joel wrote: with(ver) vers ~= Verse(id,b,c,v,t); Or, vers ~= ver;

Parsing with dxml

2019-11-17 Thread Joel via Digitalmars-d-learn
I can only parse one row successfully. I tried increasing the popFronts, till it said I'd gone off the end. Running ./app core.exception.AssertError@../../../../.dub/packages/dxml-0.4.1/dxml/source/dxml/parser.d(1457): text cannot be called with elementEnd ??:? _d_assert_msg

Re: Unexpected result with std.conv.to

2019-11-14 Thread Joel via Digitalmars-d-learn
On Friday, 15 November 2019 at 04:26:58 UTC, Jon Degenhardt wrote: On Friday, 15 November 2019 at 03:51:04 UTC, Joel wrote: I made a feature that converts, say, [9:59am] -> [10:00am] to 1 minute. but found '9'.to!int = 57 (not 9). Doesn't seem right... I'm guessing that's standard though,

Unexpected result with std.conv.to

2019-11-14 Thread Joel via Digitalmars-d-learn
I made a feature that converts, say, [9:59am] -> [10:00am] to 1 minute. but found '9'.to!int = 57 (not 9). Doesn't seem right... I'm guessing that's standard though, same with ldc.

Re: Program run fails on Windows

2019-10-29 Thread Joel via Digitalmars-d-learn
On Wednesday, 30 October 2019 at 03:56:40 UTC, Joel wrote: I have DLangUI program that works on macOS, but only compiles Windows. It returns -1. Is there a gotcha? It doesn't ask for any DLL's. Windows 10 Pro I got programs to compile and run with bindbc-sdl, for example.

Program run fails on Windows

2019-10-29 Thread Joel via Digitalmars-d-learn
I have DLangUI program that works on macOS, but only compiles Windows. It returns -1. Is there a gotcha? It doesn't ask for any DLL's. Windows 10 Pro

Re: Uninstalling DMG file

2019-10-15 Thread Joel via Digitalmars-d-learn
On Wednesday, 16 October 2019 at 02:30:58 UTC, Joel wrote: How would I go about uninstalling D's DMG file, (as I'm weary of installing it)? I usually, use Home Brew, but the lastest on that doesn't work (macOS Catalina). I guess I can just wipe off the executable files that DMG produces,

Uninstalling DMG file

2019-10-15 Thread Joel via Digitalmars-d-learn
How would I go about uninstalling D's DMG file, (as I'm weary of installing it)? I usually, use Home Brew, but the lastest on that doesn't work (macOS Catalina). I guess I can just wipe off the executable files that DMG produces, aye?

Re: Undefined symbol: _dyld_enumerate_tlv_storage (OSX)

2019-10-15 Thread Joel via Digitalmars-d-learn
On Monday, 14 October 2019 at 18:49:04 UTC, Jacob Carlborg wrote: On 2019-10-14 07:36, Joel wrote: I use Home Brew (brew upgrade dmd, and brew upgrade dub) Brew is only up to 2.087.1 at the moment - John Colvin seems to be the man that mantains dmd with brew. You can use DVM [1] to install

Re: Undefined symbol: _dyld_enumerate_tlv_storage (OSX)

2019-10-15 Thread Joel via Digitalmars-d-learn
On Monday, 14 October 2019 at 18:49:04 UTC, Jacob Carlborg wrote: On 2019-10-14 07:36, Joel wrote: I use Home Brew (brew upgrade dmd, and brew upgrade dub) Brew is only up to 2.087.1 at the moment - John Colvin seems to be the man that mantains dmd with brew. You can use DVM [1] to install

Re: Undefined symbol: _dyld_enumerate_tlv_storage (OSX)

2019-10-13 Thread Joel via Digitalmars-d-learn
On Friday, 11 October 2019 at 11:38:27 UTC, Jacob Carlborg wrote: On 2019-10-10 20:12, Robert M. Münch wrote: I have two project I want to compile and both times get this error: Undefined symbols for architecture x86_64:  "_dyld_enumerate_tlv_storage", referenced from:

Re: Input engine

2019-09-15 Thread Joel via Digitalmars-d-learn
On Sunday, 15 September 2019 at 10:52:43 UTC, rikki cattermole wrote: On 15/09/2019 12:16 PM, Joel wrote: What is a good keyboard input handler or so? Just need one that picks up that a key is down, but not like a word processor. Are you referring to when you hold down a key and multiple

Input engine

2019-09-14 Thread Joel via Digitalmars-d-learn
What is a good keyboard input handler or so? Just need one that picks up that a key is down, but not like a word processor.

Re: serve-d and spindump

2019-09-14 Thread Joel via Digitalmars-d-learn
On Saturday, 14 September 2019 at 10:14:19 UTC, psyscout wrote: On Friday, 13 September 2019 at 23:47:00 UTC, Joel wrote: [...] I had a similar issue with crazy CPU consumption when I used VS Code. The root cause for me was "autosave" and "build on save" settings turned on simultaneously.

serve-d and spindump

2019-09-13 Thread Joel via Digitalmars-d-learn
On my macOS 10.14.6 computer, I close serve-d thread when it's using too much CPU, I also knock off spindump for the same reason. I get artifacts and junk that flash on my screen - I don't know if that's connected to removing those or not. Does anyone else have these problems? I always have

Re: Name change weird

2019-09-13 Thread Joel via Digitalmars-d-learn
On Friday, 13 September 2019 at 12:20:48 UTC, H. S. Teoh wrote: On Fri, Sep 13, 2019 at 05:57:53AM +, Joel via Digitalmars-d-learn wrote: [...] jex(2204,0x75356000) malloc: Incorrect checksum for freed object 0x7ffc9368cdf8: probably modified after being freed. Corrupt value

Re: Name change weird

2019-09-13 Thread Joel via Digitalmars-d-learn
On Friday, 13 September 2019 at 10:02:35 UTC, Joel wrote: On Friday, 13 September 2019 at 09:54:58 UTC, Kagamin wrote: Maybe you upgraded SFML and now binding doesn't match? I didn't touch SFML dylibs. I guess I could try recompling them. It's a bit late here in New Zealand, though. I

Re: Name change weird

2019-09-13 Thread Joel via Digitalmars-d-learn
On Friday, 13 September 2019 at 09:54:58 UTC, Kagamin wrote: Maybe you upgraded SFML and now binding doesn't match? I didn't touch SFML dylibs. I guess I could try recompling them. It's a bit late here in New Zealand, though.

Re: Name change weird

2019-09-13 Thread Joel via Digitalmars-d-learn
On Friday, 13 September 2019 at 06:07:57 UTC, Joel wrote: On Friday, 13 September 2019 at 05:57:53 UTC, Joel wrote: On Friday, 13 September 2019 at 05:39:06 UTC, Joel wrote: [...] Actually, forget about the above. It's still crashing in run time. jex(2204,0x75356000) malloc: Incorrect

Re: Bug with profiling GC with multiple threads/fibers

2019-09-13 Thread Joel via Digitalmars-d-learn
On Sunday, 21 April 2019 at 16:20:51 UTC, WebFreak001 wrote: I'm trying to GC profile serve-d which uses a lot of fibers potentially also across some threads and some threads doing some dedicated work, however -profile=gc doesn't seem to work properly. It logs `shared static this` calls and

Re: Name change weird

2019-09-13 Thread Joel via Digitalmars-d-learn
On Friday, 13 September 2019 at 05:57:53 UTC, Joel wrote: On Friday, 13 September 2019 at 05:39:06 UTC, Joel wrote: [...] Actually, forget about the above. It's still crashing in run time. jex(2204,0x75356000) malloc: Incorrect checksum for freed object 0x7ffc9368cdf8: probably

Re: Name change weird

2019-09-13 Thread Joel via Digitalmars-d-learn
On Friday, 13 September 2019 at 05:39:06 UTC, Joel wrote: I edited one of my librarys and found my programs crashing. At first, I couldn't find what was wrong but used GitHub to review my changes. I found an enum[0] that had a name change - that my programs weren't even using. All the change

Name change weird

2019-09-12 Thread Joel via Digitalmars-d-learn
I edited one of my librarys and found my programs crashing. At first, I couldn't find what was wrong but used GitHub to review my changes. I found an enum[0] that had a name change - that my programs weren't even using. All the change that was from 'enum g_Draw {text, input}' to 'enum g_draw

Learning delegates

2019-09-08 Thread Joel via Digitalmars-d-learn
I'm trying to understand delegates. Is there any good ways I can get a better understanding of them?

Re: DlangUI print too small on retina screens

2019-04-13 Thread Joel via Digitalmars-d-learn
On Sunday, 14 April 2019 at 02:12:28 UTC, evilrat wrote: On Saturday, 13 April 2019 at 12:00:30 UTC, Joel wrote: [...] option 1 - using override DPI function: --- [...] Thanks, option 1 pretty much worked - though overrideScreenDPI didn't compile with float type (int type

Re: DlangUI print too small on retina screens

2019-04-13 Thread Joel via Digitalmars-d-learn
On Saturday, 13 April 2019 at 02:35:59 UTC, evilrat wrote: On Friday, 12 April 2019 at 08:39:52 UTC, Joel wrote: [...] It should detect DPI for you, and internally do the scaling. Though I don't know if it works at all. In case it is not yet implemented try this

DlangUI print too small on retina screens

2019-04-12 Thread Joel via Digitalmars-d-learn
I got a new computer (another MacBook Pro, but this one has retina display), now I don't think I can use my main programs (done in DlangUI), without eye strain and having my head close to the screen. I noticed a lot of forked versions of the said library. Do any have a fix for the tiny

Re: macOS Mojave compatiblity

2019-04-11 Thread Joel via Digitalmars-d-learn
On Thursday, 11 April 2019 at 23:22:19 UTC, Joel wrote: I've ordered a new computer, and it has Mojave OS. It's 64 bit only, so I'm wondering what difference would that make with things like with C bindings and stuff. For example would https://code.dlang.org/packages/dsfml and

macOS Mojave compatiblity

2019-04-11 Thread Joel via Digitalmars-d-learn
I've ordered a new computer, and it has Mojave OS. It's 64 bit only, so I'm wondering what difference would that make with things like with C bindings and stuff. For example would https://code.dlang.org/packages/dsfml and https://code.dlang.org/packages/dlangui librarys work?

Re: dub getting stuck

2019-03-19 Thread Joel via Digitalmars-d-learn
On Monday, 18 March 2019 at 20:25:14 UTC, Joel wrote: On Sunday, 17 March 2019 at 09:04:37 UTC, Eugene Wissner wrote: On Sunday, 17 March 2019 at 07:20:47 UTC, Joel wrote: macOS 10.13.6 dmd 2.085.0 dub 1.3.0 [snip] dub 1.3.0 is something old. Is it reproducable with a newer version?

Re: dub getting stuck

2019-03-18 Thread Joel via Digitalmars-d-learn
On Sunday, 17 March 2019 at 09:04:37 UTC, Eugene Wissner wrote: On Sunday, 17 March 2019 at 07:20:47 UTC, Joel wrote: macOS 10.13.6 dmd 2.085.0 dub 1.3.0 [snip] dub 1.3.0 is something old. Is it reproducable with a newer version? Can one safely update dub by it's self (Home Brew), when

dub getting stuck

2019-03-17 Thread Joel via Digitalmars-d-learn
macOS 10.13.6 dmd 2.085.0 dub 1.3.0 { "name": "server", "targetType": "executable", "description": "A testing D application.", "sourcePaths" : ["source"], "dependencies": { "vibe-d" : "~>0.8.0" } } void main() { import vibe.d;

Re: File .. byLine

2018-12-02 Thread Joel via Digitalmars-d-learn
On Monday, 3 December 2018 at 06:55:50 UTC, Nicholas Wilson wrote: On Monday, 3 December 2018 at 06:09:21 UTC, Joel wrote: [...] https://run.dlang.io/is/h0ArAB works for me. If you want it as a string not char[] then byLineCopy should work, if not just `.idup` `line`. Oh, I was using

File .. byLine

2018-12-02 Thread Joel via Digitalmars-d-learn
I can't seem to get this to work! ``` foreach(line; File("help.txt").byLine) { writeln(line.stripLeft); ``` With the code above, I get this compile error: source/app.d(360,36): Error: template std.algorithm.mutation.stripLeft cannot deduce function from argument types !()(char[]),

Home Brew dmd update 2.082

2018-10-07 Thread Joel via Digitalmars-d-learn
It's been a over a month, and there still isn't an update for dmd 2.082 on macOS using Home Brew?! I get this (with 'brew upgrade dmd'): Error: dmd 2.081.2 already installed

Re: wstring double quotes to string double quotes

2018-04-20 Thread Joel via Digitalmars-d-learn
On Friday, 20 April 2018 at 02:46:14 UTC, Jonathan M Davis wrote: On Thursday, April 19, 2018 23:24:05 Joel via Digitalmars-d-learn wrote: On Thursday, 19 April 2018 at 21:57:28 UTC, Adam D. Ruppe wrote: > [...] That worked! Thanks Adam. Given that these functions really shouldn't be th

Re: wstring double quotes to string double quotes

2018-04-19 Thread Joel via Digitalmars-d-learn
On Thursday, 19 April 2018 at 21:57:28 UTC, Adam D. Ruppe wrote: On Thursday, 19 April 2018 at 21:53:52 UTC, Joel wrote: I have a program that uses string double quotes, but copies from wstring double quotes. The wstring double quotes are in string type (sourceTxt is a string with wstring

wstring double quotes to string double quotes

2018-04-19 Thread Joel via Digitalmars-d-learn
I have a program that uses string double quotes, but copies from wstring double quotes. The wstring double quotes are in string type (sourceTxt is a string with wstring double quotes). The following code crashes with an array.d(2211): Range violation error: import std.conv : to; import

Re: Searching string for character in binary search

2018-02-25 Thread Joel via Digitalmars-d-learn
On Sunday, 25 February 2018 at 21:18:55 UTC, Joel wrote: The number tests work, but not the string one. Thanks guys. I worked it out, I thought my search code was right, since the first asserts worked.

Searching string for character in binary search

2018-02-25 Thread Joel via Digitalmars-d-learn
The number tests work, but not the string one. void main() { assert([1,2,3,4,5,6,7,8,9,10,11].binarySearch(6)); assert(! [1,2,3,4,5,7,8,9,10,11].binarySearch(6)); assert("abcdefghijklmnopqrstuvwxyz".binarySearch('j')); // not work import std.stdio; writeln("Assert tests

Re: Double link list

2018-02-24 Thread Joel via Digitalmars-d-learn
On Saturday, 24 February 2018 at 09:48:13 UTC, Joel wrote: I'm trying some code for practice, but it isn't working properly - it prints just one number when printing in reverse. [snip] Thanks guys. And I got it working with 'if (head is tail)' etc.

Double link list

2018-02-24 Thread Joel via Digitalmars-d-learn
I'm trying some code for practice, but it isn't working properly - it prints just one number when printing in reverse. ''' void main() { import std.stdio, std.algorithm, std.range, std.conv; struct List(T) { class Node { T value;

Re: macOS preview D files

2018-02-07 Thread Joel via Digitalmars-d-learn
On Wednesday, 7 February 2018 at 12:45:43 UTC, Jacob Carlborg wrote: On 2018-02-07 02:24, Joel wrote: Using finder, I want to see D files shown in the preview column, I some times have with TextMate. Also on my iPhone (in iCloud app, open as a text file) would be a bonus too. D is not

macOS preview D files

2018-02-06 Thread Joel via Digitalmars-d-learn
Using finder, I want to see D files shown in the preview column, I some times have with TextMate. Also on my iPhone (in iCloud app, open as a text file) would be a bonus too.

Re: workspace-d dsymbol Visual Code macOS

2018-02-06 Thread Joel via Digitalmars-d-learn
[snip] On Tuesday, 6 February 2018 at 20:59:54 UTC, WebFreak001 wrote: can you try git clone https://github.com/Pure-D/workspace-d.git cd workspace-d dub upgrade dub build and then put the resulting path of the executables in your user settings as "d.workspacedPath" I got the same compile

Re: workspace-d dsymbol Visual Code macOS

2018-02-06 Thread Joel via Digitalmars-d-learn
On Tuesday, 6 February 2018 at 19:36:54 UTC, WebFreak001 wrote: On Tuesday, 6 February 2018 at 05:41:19 UTC, Joel wrote: I'm using a macOS (10.12.6) computer. workspace-d used to work, but now it says it's not installed, (I think since I quit out of Visual Code before shutting down the

workspace-d dsymbol Visual Code macOS

2018-02-05 Thread Joel via Digitalmars-d-learn
I'm using a macOS (10.12.6) computer. workspace-d used to work, but now it says it's not installed, (I think since I quit out of Visual Code before shutting down the computer). I tried compiling with with the option, but got this: Installing into

Re: dub test

2018-02-02 Thread Joel via Digitalmars-d-learn
On Friday, 2 February 2018 at 09:00:38 UTC, carblue wrote: On Friday, 2 February 2018 at 07:23:54 UTC, Joel wrote: [snip] Import module base from file ... source/jmisc/base.d by: import jmisc.base; and recommended read: https://code.dlang.org/package-format?lang=json Thanks carblue. I had

dub test

2018-02-01 Thread Joel via Digitalmars-d-learn
When I try 'dub test' I get errors like 'Source file '/Users/joelchristensen/jpro/dpro2/JMiscLib/source/jmisc/base.d' not found in any import path.' Here's the dub.json file I'm using: ``` { "name": "timelog", "targetType": "executable", "description": "A Joel D program. A

Re: How to test a DUB-based library during development?

2018-01-30 Thread Joel via Digitalmars-d-learn
On Thursday, 11 January 2018 at 12:36:22 UTC, Guillaume Piolat wrote: On Thursday, 11 January 2018 at 12:27:27 UTC, DanielG wrote: [snip] You may have some unittest blocks in your source files, and then type: $ dub test [snip] When I try 'dub test' I get errors like 'Source file

Re: StopWatch problem

2017-12-05 Thread Joel via Digitalmars-d-learn
On Tuesday, 5 December 2017 at 21:45:20 UTC, Jonathan M Davis wrote: On Tuesday, December 05, 2017 21:33:53 Joel via Digitalmars-d-learn wrote: [...] core.time.msecs is an alias for core.time.dur!"msecs". It takes a long for the number of milliseconds and returns a Duration. I

StopWatch problem

2017-12-05 Thread Joel via Digitalmars-d-learn
void main() { import std.datetime: Duration, msecs; import std.datetime.stopwatch: StopWatch; StopWatch sw; if (sw.peek.msecs) { } } I get this error with the code: z.d(6): Error: function core.time.dur!"msecs".dur (long length) is not

Re: if (int bar = .. bug or some thing

2017-10-30 Thread Joel via Digitalmars-d-learn
Ok, thanks guys.

if (int bar = .. bug or some thing

2017-10-30 Thread Joel via Digitalmars-d-learn
The following code assert fails (bar == 1, not -10!). I've wasted a bit of time because of this happening. void main() { if (int bar = foo() != 0) { assert(bar == -10); } } auto foo() { return -10; }

Re: Using dates to get days count

2017-09-29 Thread Joel via Digitalmars-d-learn
On Friday, 29 September 2017 at 06:32:19 UTC, rikki cattermole wrote: On 29/09/2017 7:29 AM, Joel wrote: How do I count the days between to dates? https://dlang.org/phobos/std_datetime_date.html#.Date.opBinary.2 https://dlang.org/phobos/core_time.html#.Duration.total Thanks rikki. I did

Using dates to get days count

2017-09-29 Thread Joel via Digitalmars-d-learn
How do I count the days between to dates?

Re: Day of week from date

2017-09-28 Thread Joel via Digitalmars-d-learn
Thanks guys. :-D

Day of week from date

2017-09-28 Thread Joel via Digitalmars-d-learn
With a given date, I want to know what day it is (like Sunday, Monday, etc). I had a look up on std.datetime, and core.time, but they don't seem to have a function for it.

Re: Crazy compile time errors with DMD 2.075.1 & 2.076.0

2017-09-03 Thread Joel via Digitalmars-d-learn
On Monday, 4 September 2017 at 04:45:27 UTC, Jonathan M Davis wrote: On Sunday, September 03, 2017 21:22:14 Ali Çehreli via Digitalmars-d-learn wrote: [...] Much as some people have been doing it for some reason, I really don't understand why anyone would be unzipping the .zip file on top

Crazy compile time errors with DMD 2.075.1 & 2.076.0

2017-09-03 Thread Joel via Digitalmars-d-learn
One of my small programs doesn't compile any more since, said, DMD versions. I've got other programs that do work, but I can't see what's different about them?! I'm using macOS. [1] Here is the program and stuff. It uses DSFML 2.1.1, but I haven't added the dynamic files for it. giver

Re: 2D game physics, macOS

2017-07-13 Thread Joel via Digitalmars-d-learn
On Thursday, 13 July 2017 at 09:53:05 UTC, Jacob Carlborg wrote: On 2017-07-13 02:34, Joel wrote: It doesn't look like there's any thing I can use. I've come across: dbox, dchip, and blaze. Blaze is dsource. dbox is alpha and hasn't been updated for 3 years. dchip [1] hasn't been updated

Re: 2D game physics, macOS

2017-07-12 Thread Joel via Digitalmars-d-learn
On Wednesday, 12 July 2017 at 12:05:33 UTC, Jacob Carlborg wrote: On 2017-07-12 12:18, Joel wrote: Is there a 2D physics library I can use on macOS, with D? I already use a multimedia library for graphics, sound and input. Box2D [1] perhaps. I think I've seen bindings for it, somewhere.

2D game physics, macOS

2017-07-12 Thread Joel via Digitalmars-d-learn
Is there a 2D physics library I can use on macOS, with D? I already use a multimedia library for graphics, sound and input.

Re: implib.exe no output files

2017-06-23 Thread Joel via Digitalmars-d-learn
On Wednesday, 21 June 2017 at 11:30:56 UTC, Ivan Kazmenko wrote: [...] Step 5. I don't get any lib files. I got lib files on another computer, though.

Re: implib.exe no output files

2017-06-19 Thread Joel via Digitalmars-d-learn
On Sunday, 18 June 2017 at 09:48:31 UTC, Ivan Kazmenko wrote: On Sunday, 18 June 2017 at 07:41:27 UTC, Joel wrote: I got the file here: http://ftp.digitalmars.com/bup.zip It works on other computers. I was trying to update to the latest DAllegro (https://github.com/SiegeLord/DAllegro5).

implib.exe no output files

2017-06-18 Thread Joel via Digitalmars-d-learn
I got the file here: http://ftp.digitalmars.com/bup.zip It works on other computers. I was trying to update to the latest DAllegro (https://github.com/SiegeLord/DAllegro5). Though, I used another computer for the lib files and still couldn't get the latest DAllegro5 working.

Re: brew install dmd

2017-06-11 Thread Joel via Digitalmars-d-learn
On Sunday, 11 June 2017 at 04:08:56 UTC, Seb wrote: But I'm not sure about doing this. This is a copy of the __official__ D installer as advertised on dlang.org (http://dlang.org/download.html): curl -fsS https://dlang.org/install.sh | bash -s dmd (the releases are signed) i.dlang.io is

Re: brew install dmd

2017-06-10 Thread Joel via Digitalmars-d-learn
On Sunday, 11 June 2017 at 03:54:05 UTC, Mike Parker wrote: On Sunday, 11 June 2017 at 03:48:57 UTC, Joel wrote: curl https://i.dlang.io | bash -s But I'm not sure about doing this. I'm don't what that means, but Homebrew is giving you 2.074.1, it's just that the binary has the wrong

Re: brew install dmd

2017-06-10 Thread Joel via Digitalmars-d-learn
On Sunday, 11 June 2017 at 02:38:21 UTC, Mike Parker wrote: On Sunday, 11 June 2017 at 01:30:37 UTC, Joel wrote: but still 2.074.0 (not 74.1) Joels-MacBook-Pro:Testing joelchristensen$ dmd DMD64 D Compiler v2.074.0 It's probably related to this:

brew install dmd

2017-06-10 Thread Joel via Digitalmars-d-learn
but still 2.074.0 (not 74.1) I'm not that familier brew. I've tried `brew upgrade` and `brew update`. Joels-MacBook-Pro:Testing joelchristensen$ brew upgrade dmd ==> Upgrading 1 outdated package, with result: dmd 2.074.1 ==> Upgrading dmd ==> Downloading

Re: SFML gcc - MacOS

2017-04-17 Thread Joel via Digitalmars-d-learn
On Monday, 17 April 2017 at 08:48:06 UTC, Jacob Carlborg wrote: On 2017-04-16 10:11, Joel wrote: I've got Xcode, do I enter `xcode-select --install` in the terminal? Yes. That will get you access to Clang, the linker and other tools on the command line. It will also create /usr/include

Re: D version of C# code

2017-04-16 Thread Joel via Digitalmars-d-learn
On Sunday, 16 April 2017 at 09:46:13 UTC, ag0aep6g wrote: On 04/16/2017 11:20 AM, Joel wrote: [...] void main() { // Arrange const string templateString = "My {pet} has {number} {ailment}."; auto pairs = [ "pet": "dog", "number": "5", "ailment": "fleas",

D version of C# code

2017-04-16 Thread Joel via Digitalmars-d-learn
What would you put instead of this C# code, in D? ```C# // Arrange const string templateString = "My {pet} has {number} {ailment}."; var pairs = new { pet = "dog", number = 5, ailment = "fleas",

Re: SFML gcc - MacOS

2017-04-16 Thread Joel via Digitalmars-d-learn
On Sunday, 16 April 2017 at 07:53:49 UTC, Jacob Carlborg wrote: On 2017-04-16 03:52, Joel wrote: In getting DSFML (http://dsfml.com/) working. I found gcc takes for ever to install, is there some thing wrong? (I posted in https://github.com/Jebbs/DSFML, but no replies). Maybe just install

SFML gcc - MacOS

2017-04-15 Thread Joel via Digitalmars-d-learn
In getting DSFML (http://dsfml.com/) working. I found gcc takes for ever to install, is there some thing wrong? (I posted in https://github.com/Jebbs/DSFML, but no replies). Maybe just install Xcode CLT (some how), and uninstall gcc. I've had this problem for a while now. I would appreciate

pointer not aligned

2017-03-30 Thread Joel via Digitalmars-d-learn
Linking... ld: warning: pointer not aligned at address 0x10017A4C9 (_D30TypeInfo_AxS3std4file8DirEntry6__initZ + 16 from .dub/build/application-debug-posix.osx-x86_64-dmd_2072-EFDCDF4D45F944F7A9B1AEA5C32F81ED/spellit.o) ... and this goes on forever!

  1   2   >