digitalmars.D - Inconsistent coding style in code examples
- H. S. Teoh via Digitalmars-d (27/27) Feb 10 2015 This PR:
- Meta (2/42) Feb 10 2015 I hate 2-space tabs as much as I hate 8-space tabs.
- Andrei Alexandrescu (3/4) Feb 10 2015 When I joined Facebook (2-space indent and 80 columns) I couldn't
- Walter Bright (2/3) Feb 10 2015 You'll hate 4-space if you read it on an ereader.
- Andrei Alexandrescu (3/12) Feb 10 2015 Yah, I've adjusted spacing. That kind of change must be done wholesale
- Andrei Alexandrescu (3/18) Feb 10 2015 Forgot:
- Walter Bright (11/13) Feb 10 2015 My Kindle 3 has a 37 character screen width when using a monospace font ...
- Andrei Alexandrescu (3/16) Feb 10 2015 It's a good reason (e.g. TDPL uses 3 spaces throughout). We just can't
- Steven Schveighoffer (9/22) Feb 10 2015 Kindles are supposed to be very good at resizing text for user
- Jacob Carlborg (4/8) Feb 11 2015 I agree.
- Vladimir Panteleev (4/14) Feb 10 2015 Isn't this problem better solved mechanically?
- H. S. Teoh via Digitalmars-d (96/111) Feb 10 2015 This would trigger another interminable thread about the merits/cons of
- H. S. Teoh via Digitalmars-d (13/20) Feb 11 2015 [...]
- Vladimir Panteleev (3/6) Feb 11 2015 I think you can run DM make under Wine.
- H. S. Teoh via Digitalmars-d (6/13) Feb 11 2015 Interesting.
- ketmar (4/7) Feb 11 2015 yep, the whole dmd can be built under wine, using tools from dmc and dmc...
- Walter Bright (2/5) Feb 11 2015 Bugzilla issue?
- ketmar (4/10) Feb 11 2015 sure i did, along with the patch:
- Walter Bright (3/13) Feb 11 2015 Yes, just making sure it's the same issue, and not something that hasn't...
- ketmar (3/21) Feb 11 2015 no, i didn't found anything else. with this patch dmd with wine works=20
- Walter Bright (2/4) Feb 11 2015 Thanks again for finding the problem and posting a fix.
- ketmar (4/9) Feb 12 2015 now i feel ashamed, 'cause i did that for my own profit, and you are=20
- Walter Bright (9/18) Feb 12 2015 Why you did it doesn't matter. What matters is you did it and contribute...
- H. S. Teoh via Digitalmars-d (6/11) Feb 12 2015 What does that say about the current D bugtracker? ;-)
- Walter Bright (2/10) Feb 12 2015 It says it's easy to submit bug reports for D.
- H. S. Teoh via Digitalmars-d (9/21) Feb 12 2015 Generally, I agree. But OTOH, we *did* have people complaining on the
- Walter Bright (5/12) Feb 12 2015 The reason bugzilla requires a signup is because whatever is posted ther...
- weaselcat (3/16) Feb 12 2015 D bug tracker is easy to use to the point where sometimes I think
- H. S. Teoh via Digitalmars-d (5/23) Feb 12 2015 Don't worry, you won't outdo bearophile, our resident bugbear. ;-)
- Vladimir Panteleev (4/9) Feb 12 2015 Maybe print the Bugzilla URL on compiler ICEs? :)
- ketmar (7/17) Feb 12 2015 and as far as i know that never helps much. 'cause what people see is th...
- Walter Bright (3/10) Feb 12 2015 Right on dlang.org under [Resources] there's [Bug Tracker]. I don't beli...
- Jacob Carlborg (4/6) Feb 13 2015 I had no idea that link existed :)
- ketmar (10/18) Feb 12 2015 that's exactly why i'm ashamed. 'cause i knew about this bug for almost ...
- Walter Bright (2/6) Feb 12 2015 I agree. It's easy to report bugs, and we don't try and hide them.
- Vladimir Panteleev (3/5) Feb 11 2015 You can find .mobi viewers online. Amazon provides some as well,
- Walter Bright (3/6) Feb 11 2015 1. I've seen Kindles at the pawn shop for $35.
- Mike Parker (2/8) Feb 12 2015 Amazon has free Kindle apps for several platforms.
- Mengu (4/44) Feb 13 2015 as a ruby dev, i'm fine with 2-space indentation and as a python
This PR: https://github.com/D-Programming-Language/phobos/pull/2973 introduces a code example with 2-space indentation, whereas the rest of Phobos and dlang.org uses 4-space indentation. I don't like this. It's inconsistent, and is detracting from the professional look of D. It's bad enough that we are inconsistent from one page to another, it's even worse that this PR introduces a style inconsistency within a *single* doc page. It makes D look amateurish and unprofessional. Walter's reason for this is that 4-space indentation makes it look bad on Kindle and other small-screen readers. Which is a good point, but it shouldn't be reason for inconsistent code style throughout dlang.org. If we decide that 4-space indentation is no good, then we should switch *wholesale* to whatever it is we deem good. We should not be introducing arbitrary style differences on an ad hoc basis. So, what will it be? What coding style should we use for official language docs? Should we use 4-space indentation or 2-space indentation? Should we reduce the maximum line length in code samples so that they don't look horribly on narrow-width readers? Or something else altogether? (Note also, that the code example in question is part of a ddoc'd unittest, which means it is also inconsistent with the rest of Phobos code. This is a smaller issue than inconsistency in public-facing docs, but nonetheless, it's an annoying one.) T -- Любишь кататься - люби и саночки возить.
Feb 10 2015
On Tuesday, 10 February 2015 at 21:00:11 UTC, H. S. Teoh wrote:This PR: https://github.com/D-Programming-Language/phobos/pull/2973 introduces a code example with 2-space indentation, whereas the rest of Phobos and dlang.org uses 4-space indentation. I don't like this. It's inconsistent, and is detracting from the professional look of D. It's bad enough that we are inconsistent from one page to another, it's even worse that this PR introduces a style inconsistency within a *single* doc page. It makes D look amateurish and unprofessional. Walter's reason for this is that 4-space indentation makes it look bad on Kindle and other small-screen readers. Which is a good point, but it shouldn't be reason for inconsistent code style throughout dlang.org. If we decide that 4-space indentation is no good, then we should switch *wholesale* to whatever it is we deem good. We should not be introducing arbitrary style differences on an ad hoc basis. So, what will it be? What coding style should we use for official language docs? Should we use 4-space indentation or 2-space indentation? Should we reduce the maximum line length in code samples so that they don't look horribly on narrow-width readers? Or something else altogether? (Note also, that the code example in question is part of a ddoc'd unittest, which means it is also inconsistent with the rest of Phobos code. This is a smaller issue than inconsistency in public-facing docs, but nonetheless, it's an annoying one.) TI hate 2-space tabs as much as I hate 8-space tabs.
Feb 10 2015
On 2/10/15 1:09 PM, Meta wrote:I hate 2-space tabs as much as I hate 8-space tabs.When I joined Facebook (2-space indent and 80 columns) I couldn't believe my eyes. Then I got used to it. -- Andrei
Feb 10 2015
On 2/10/2015 1:09 PM, Meta wrote:I hate 2-space tabs as much as I hate 8-space tabs.You'll hate 4-space if you read it on an ereader.
Feb 10 2015
On 2/10/15 12:57 PM, H. S. Teoh via Digitalmars-d wrote:This PR: https://github.com/D-Programming-Language/phobos/pull/2973 introduces a code example with 2-space indentation, whereas the rest of Phobos and dlang.org uses 4-space indentation. I don't like this. It's inconsistent, and is detracting from the professional look of D. It's bad enough that we are inconsistent from one page to another, it's even worse that this PR introduces a style inconsistency within a *single* doc page. It makes D look amateurish and unprofessional.Yah, I've adjusted spacing. That kind of change must be done wholesale if we commit to it. -- Andrei
Feb 10 2015
On 2/10/15 1:13 PM, Andrei Alexandrescu wrote:On 2/10/15 12:57 PM, H. S. Teoh via Digitalmars-d wrote:Forgot: https://github.com/D-Programming-Language/phobos/commit/38802decf57fb6e1ca81c7ee72d9b6635c0d22afThis PR: https://github.com/D-Programming-Language/phobos/pull/2973 introduces a code example with 2-space indentation, whereas the rest of Phobos and dlang.org uses 4-space indentation. I don't like this. It's inconsistent, and is detracting from the professional look of D. It's bad enough that we are inconsistent from one page to another, it's even worse that this PR introduces a style inconsistency within a *single* doc page. It makes D look amateurish and unprofessional.Yah, I've adjusted spacing. That kind of change must be done wholesale if we commit to it. -- Andrei
Feb 10 2015
On 2/10/2015 12:57 PM, H. S. Teoh via Digitalmars-d wrote:Walter's reason for this is that 4-space indentation makes it look bad on Kindle and other small-screen readers.My Kindle 3 has a 37 character screen width when using a monospace font (i.e. code font). Trying to read code formatted to 80 columns on it is just awful. While I don't expect anyone to read Phobos source code on a Kindle, I do expect the ereader version of the documentation to be read on the Kindle (or phone or whatever ereader). Vertical space is also far more important on the small screen. Having a different whitespace convention for documentation makes sense. (Such constraints also come in to play when writing books and articles.) At one point I had done this for all the examples in the D language spec, but I've never done it for the Phobos docs.
Feb 10 2015
On 2/10/15 1:20 PM, Walter Bright wrote:On 2/10/2015 12:57 PM, H. S. Teoh via Digitalmars-d wrote:It's a good reason (e.g. TDPL uses 3 spaces throughout). We just can't start doing it randomly in one unrelated diff. -- AndreiWalter's reason for this is that 4-space indentation makes it look bad on Kindle and other small-screen readers.My Kindle 3 has a 37 character screen width when using a monospace font (i.e. code font). Trying to read code formatted to 80 columns on it is just awful. While I don't expect anyone to read Phobos source code on a Kindle, I do expect the ereader version of the documentation to be read on the Kindle (or phone or whatever ereader). Vertical space is also far more important on the small screen. Having a different whitespace convention for documentation makes sense. (Such constraints also come in to play when writing books and articles.) At one point I had done this for all the examples in the D language spec, but I've never done it for the Phobos docs.
Feb 10 2015
On 2/10/15 4:20 PM, Walter Bright wrote:On 2/10/2015 12:57 PM, H. S. Teoh via Digitalmars-d wrote:Kindles are supposed to be very good at resizing text for user preference. This seems like the generated format for the kindle isn't properly annotated. Please, let's not cater to kindles in ddoc. The documentation is generated first and foremost for dlang.org. If you want to write a script to make a book out of it, fine, but screwing up the web site for the sake of the few people that use kindles is ridiculous. -SteveWalter's reason for this is that 4-space indentation makes it look bad on Kindle and other small-screen readers.My Kindle 3 has a 37 character screen width when using a monospace font (i.e. code font). Trying to read code formatted to 80 columns on it is just awful. While I don't expect anyone to read Phobos source code on a Kindle, I do expect the ereader version of the documentation to be read on the Kindle (or phone or whatever ereader). Vertical space is also far more important on the small screen. Having a different whitespace convention for documentation makes sense. (Such constraints also come in to play when writing books and articles.) At one point I had done this for all the examples in the D language spec, but I've never done it for the Phobos docs.
Feb 10 2015
On 2015-02-10 22:36, Steven Schveighoffer wrote:Please, let's not cater to kindles in ddoc. The documentation is generated first and foremost for dlang.org. If you want to write a script to make a book out of it, fine, but screwing up the web site for the sake of the few people that use kindles is ridiculous.I agree. -- /Jacob Carlborg
Feb 11 2015
On Tuesday, 10 February 2015 at 21:21:14 UTC, Walter Bright wrote:On 2/10/2015 12:57 PM, H. S. Teoh via Digitalmars-d wrote:Isn't this problem better solved mechanically? (If we used tabs for indentation, it would be as simple as setting the tab width...)Walter's reason for this is that 4-space indentation makes it look bad on Kindle and other small-screen readers.My Kindle 3 has a 37 character screen width when using a monospace font (i.e. code font). Trying to read code formatted to 80 columns on it is just awful. While I don't expect anyone to read Phobos source code on a Kindle, I do expect the ereader version of the documentation to be read on the Kindle (or phone or whatever ereader).
Feb 10 2015
On Tue, Feb 10, 2015 at 09:44:17PM +0000, Vladimir Panteleev via Digitalmars-d wrote:On Tuesday, 10 February 2015 at 21:21:14 UTC, Walter Bright wrote:That's what crossed my mind too... but:On 2/10/2015 12:57 PM, H. S. Teoh via Digitalmars-d wrote:Isn't this problem better solved mechanically?Walter's reason for this is that 4-space indentation makes it look bad on Kindle and other small-screen readers.My Kindle 3 has a 37 character screen width when using a monospace font (i.e. code font). Trying to read code formatted to 80 columns on it is just awful. While I don't expect anyone to read Phobos source code on a Kindle, I do expect the ereader version of the documentation to be read on the Kindle (or phone or whatever ereader).(If we used tabs for indentation, it would be as simple as setting the tab width...)This would trigger another interminable thread about the merits/cons of tabs vs. spaces. :-D Given that current Phobos code standardized on 4 spaces, no tab characters, I can't see tabs ever making it into Phobos code. (It would be one giant blotch of a PR that reformats every single file in Phobos and essentially be a black-out point of `git blame`... it would be a prime example of what Andrei has been complaining about of late, that much effort is spent on trivial things that only has marginal value.) That leaves the mechanical solution, which is actually very easy. It doesn't have to be a sophisticated solution involving a full-blown D lexer. It could be as simple as substituting initial runs of spaces on each line, since we already know our input to be formatted in a certain way. Proof of concept: import std.range.primitives; auto reIndent(R)(R range, size_t inputIndent, size_t outputIndent) if (isInputRange!R && is(ElementType!R : const(char)[])) { import std.algorithm.iteration : map; import std.array; import std.regex; auto reSplitInitialSpace = regex(`^( +)(.*)`); auto reReindent = regex(" ".replicate(inputIndent)); string outIndent = " ".replicate(outputIndent); return range.map!((line) { auto m = line.match(reSplitInitialSpace); if (m) { auto newIndent = m.captures[1].replaceAll(reReindent, outIndent); return newIndent ~ m.captures[2]; } else return line; }); } void main(string[] args) { import std.algorithm.iteration : map; import std.algorithm.mutation : copy; import std.stdio; stdin.byLine .reIndent(4, 2) .map!(line => line ~ "\n") .copy(stdout.lockingTextWriter()); } Output of program, given its own source code as input: import std.range.primitives; auto reIndent(R)(R range, size_t inputIndent, size_t outputIndent) if (isInputRange!R && is(ElementType!R : const(char)[])) { import std.algorithm.iteration : map; import std.array; import std.regex; auto reSplitInitialSpace = regex(`^( +)(.*)`); auto reReindent = regex(" ".replicate(inputIndent)); string outIndent = " ".replicate(outputIndent); return range.map!((line) { auto m = line.match(reSplitInitialSpace); if (m) { auto newIndent = m.captures[1].replaceAll(reReindent, outIndent); return newIndent ~ m.captures[2]; } else return line; }); } void main(string[] args) { import std.algorithm.iteration : map; import std.algorithm.mutation : copy; import std.stdio; stdin.byLine .reIndent(4, 2) .map!(line => line ~ "\n") .copy(stdout.lockingTextWriter()); } Q.E.D. :-D So all we need to do, is to add this tool to the dlang.org repo, and run each generated code example through it, and we're done. No need to reformat the entire Phobos codebase, or any of that nonsense. T -- It won't be covered in the book. The source code has to be useful for something, after all. -- Larry Wall
Feb 10 2015
On Tue, Feb 10, 2015 at 02:25:01PM -0800, H. S. Teoh via Digitalmars-d wrote: [...]That leaves the mechanical solution, which is actually very easy. It doesn't have to be a sophisticated solution involving a full-blown D lexer. It could be as simple as substituting initial runs of spaces on each line, since we already know our input to be formatted in a certain way. Proof of concept:[...] Now a full-blown tools PR: https://github.com/D-Programming-Language/tools/pull/159 I was going to attempt to do a PR for dlang.org that uses this tool for the kindle targets, but the fact that (1) I don't even have kindlegen, and (2) I don't have a Windows machine to test changes to win32.mak, means I can't test anything at all, so I'm thinking twice about attempting that. T -- If you're not part of the solution, you're part of the precipitate.
Feb 11 2015
On Wednesday, 11 February 2015 at 18:30:13 UTC, H. S. Teoh wrote:but the fact that (1) I don't even have kindlegen,It's a free download. Not FOSS though, binary blob.and (2) I don't have a Windows machine to test changes to win32.mak,I think you can run DM make under Wine.
Feb 11 2015
On Wed, Feb 11, 2015 at 06:32:27PM +0000, Vladimir Panteleev via Digitalmars-d wrote:On Wednesday, 11 February 2015 at 18:30:13 UTC, H. S. Teoh wrote:But what's the use if I don't have kindle for viewing the results?but the fact that (1) I don't even have kindlegen,It's a free download. Not FOSS though, binary blob.Interesting. T -- The only difference between male factor and malefactor is just a little emptiness inside.and (2) I don't have a Windows machine to test changes to win32.mak,I think you can run DM make under Wine.
Feb 11 2015
On Wed, 11 Feb 2015 10:51:19 -0800, H. S. Teoh via Digitalmars-d wrote:yep, the whole dmd can be built under wine, using tools from dmc and dmc=20 itself. everything works like a charm (except dmd.exe itself, which is=20 broken ;-).=Interesting.and (2) I don't have a Windows machine to test changes to win32.mak,I think you can run DM make under Wine.
Feb 11 2015
On 2/11/2015 1:37 PM, ketmar wrote:yep, the whole dmd can be built under wine, using tools from dmc and dmc itself. everything works like a charm (except dmd.exe itself, which is broken ;-).Bugzilla issue?
Feb 11 2015
On Wed, 11 Feb 2015 14:21:41 -0800, Walter Bright wrote:On 2/11/2015 1:37 PM, ketmar wrote:sure i did, along with the patch: https://issues.dlang.org/show_bug.cgi?id=3D14097 you have seen that.=yep, the whole dmd can be built under wine, using tools from dmc and dmc itself. everything works like a charm (except dmd.exe itself, which is broken ;-).=20 Bugzilla issue?
Feb 11 2015
On 2/11/2015 2:34 PM, ketmar wrote:On Wed, 11 Feb 2015 14:21:41 -0800, Walter Bright wrote:Yes, just making sure it's the same issue, and not something that hasn't been filed. Thank you.On 2/11/2015 1:37 PM, ketmar wrote:sure i did, along with the patch: https://issues.dlang.org/show_bug.cgi?id=14097 you have seen that.yep, the whole dmd can be built under wine, using tools from dmc and dmc itself. everything works like a charm (except dmd.exe itself, which is broken ;-).Bugzilla issue?
Feb 11 2015
On Wed, 11 Feb 2015 15:21:59 -0800, Walter Bright wrote:On 2/11/2015 2:34 PM, ketmar wrote:no, i didn't found anything else. with this patch dmd with wine works=20 perfectly -- no crashes since then.=On Wed, 11 Feb 2015 14:21:41 -0800, Walter Bright wrote:=20 =20 Yes, just making sure it's the same issue, and not something that hasn't been filed. Thank you.On 2/11/2015 1:37 PM, ketmar wrote:sure i did, along with the patch: https://issues.dlang.org/show_bug.cgi?id=3D14097 you have seen that.yep, the whole dmd can be built under wine, using tools from dmc and dmc itself. everything works like a charm (except dmd.exe itself, which is broken ;-).Bugzilla issue?
Feb 11 2015
On 2/11/2015 3:34 PM, ketmar wrote:no, i didn't found anything else. with this patch dmd with wine works perfectly -- no crashes since then.Thanks again for finding the problem and posting a fix.
Feb 11 2015
On Wed, 11 Feb 2015 16:09:59 -0800, Walter Bright wrote:On 2/11/2015 3:34 PM, ketmar wrote:now i feel ashamed, 'cause i did that for my own profit, and you are=20 thanking me like i did a big job fixing bug that nobody except me ever=20 seen. ;-)=no, i didn't found anything else. with this patch dmd with wine works perfectly -- no crashes since then.=20 Thanks again for finding the problem and posting a fix.
Feb 12 2015
On 2/12/2015 1:46 AM, ketmar wrote:On Wed, 11 Feb 2015 16:09:59 -0800, Walter Bright wrote:Why you did it doesn't matter. What matters is you did it and contributed it. Also, just because it wasn't reported before doesn't mean it wasn't happening to people. The vast majority will see a bug, and just dump the compiler and move to something else. Me, for example, I very very rarely bother to report a bug in a product I use. The reason isn't because I am lazy (although I am). It's because companies make it hard to report a bug. If they want to act like they're doing me a favor by accepting a bug report, then I won't bother.On 2/11/2015 3:34 PM, ketmar wrote:now i feel ashamed, 'cause i did that for my own profit, and you are thanking me like i did a big job fixing bug that nobody except me ever seen. ;-)no, i didn't found anything else. with this patch dmd with wine works perfectly -- no crashes since then.Thanks again for finding the problem and posting a fix.
Feb 12 2015
On Thu, Feb 12, 2015 at 12:16:38PM -0800, Walter Bright via Digitalmars-d wrote: [...]Me, for example, I very very rarely bother to report a bug in a product I use. The reason isn't because I am lazy (although I am). It's because companies make it hard to report a bug. If they want to act like they're doing me a favor by accepting a bug report, then I won't bother.What does that say about the current D bugtracker? ;-) T -- Ignorance is bliss... until you suffer the consequences!
Feb 12 2015
On 2/12/2015 12:20 PM, H. S. Teoh via Digitalmars-d wrote:On Thu, Feb 12, 2015 at 12:16:38PM -0800, Walter Bright via Digitalmars-d wrote: [...]It says it's easy to submit bug reports for D.Me, for example, I very very rarely bother to report a bug in a product I use. The reason isn't because I am lazy (although I am). It's because companies make it hard to report a bug. If they want to act like they're doing me a favor by accepting a bug report, then I won't bother.What does that say about the current D bugtracker? ;-)
Feb 12 2015
On Thu, Feb 12, 2015 at 12:55:40PM -0800, Walter Bright via Digitalmars-d wrote:On 2/12/2015 12:20 PM, H. S. Teoh via Digitalmars-d wrote:Generally, I agree. But OTOH, we *did* have people complaining on the forums every now and then that they found bugzilla hard to use, unfriendly, requires signing up for Yet Another Account, ad nauseaum. Would *you* go through the trouble of signing up for bugzilla if you were only a casual user of D? T -- There's light at the end of the tunnel. It's the oncoming train.On Thu, Feb 12, 2015 at 12:16:38PM -0800, Walter Bright via Digitalmars-d wrote: [...]It says it's easy to submit bug reports for D.Me, for example, I very very rarely bother to report a bug in a product I use. The reason isn't because I am lazy (although I am). It's because companies make it hard to report a bug. If they want to act like they're doing me a favor by accepting a bug report, then I won't bother.What does that say about the current D bugtracker? ;-)
Feb 12 2015
On 2/12/2015 1:03 PM, H. S. Teoh via Digitalmars-d wrote:On Thu, Feb 12, 2015 at 12:55:40PM -0800, Walter Bright via Digitalmars-d wrote:The reason bugzilla requires a signup is because whatever is posted there shows up to the public without any moderation, so it is ripe for being a spam delivery system. I.e. it's more than just a bug *reporting* system. If it was a reporting system only, then an email address would be more appropriate.It says it's easy to submit bug reports for D.Generally, I agree. But OTOH, we *did* have people complaining on the forums every now and then that they found bugzilla hard to use, unfriendly, requires signing up for Yet Another Account, ad nauseaum. Would *you* go through the trouble of signing up for bugzilla if you were only a casual user of D?
Feb 12 2015
On Thursday, 12 February 2015 at 20:22:42 UTC, H. S. Teoh wrote:On Thu, Feb 12, 2015 at 12:16:38PM -0800, Walter Bright via Digitalmars-d wrote: [...]D bug tracker is easy to use to the point where sometimes I think I might be submitting too many reports.Me, for example, I very very rarely bother to report a bug in a product I use. The reason isn't because I am lazy (although I am). It's because companies make it hard to report a bug. If they want to act like they're doing me a favor by accepting a bug report, then I won't bother.What does that say about the current D bugtracker? ;-) T
Feb 12 2015
On Thu, Feb 12, 2015 at 10:47:28PM +0000, weaselcat via Digitalmars-d wrote:On Thursday, 12 February 2015 at 20:22:42 UTC, H. S. Teoh wrote:Don't worry, you won't outdo bearophile, our resident bugbear. ;-) T -- If it's green, it's biology, If it stinks, it's chemistry, If it has numbers it's math, If it doesn't work, it's technology.On Thu, Feb 12, 2015 at 12:16:38PM -0800, Walter Bright via Digitalmars-d wrote: [...]D bug tracker is easy to use to the point where sometimes I think I might be submitting too many reports.Me, for example, I very very rarely bother to report a bug in a product I use. The reason isn't because I am lazy (although I am). It's because companies make it hard to report a bug. If they want to act like they're doing me a favor by accepting a bug report, then I won't bother.What does that say about the current D bugtracker? ;-) T
Feb 12 2015
On Thursday, 12 February 2015 at 20:16:40 UTC, Walter Bright wrote:Me, for example, I very very rarely bother to report a bug in a product I use. The reason isn't because I am lazy (although I am). It's because companies make it hard to report a bug. If they want to act like they're doing me a favor by accepting a bug report, then I won't bother.Maybe print the Bugzilla URL on compiler ICEs? :) I think gcc does that.
Feb 12 2015
On Thu, 12 Feb 2015 21:12:26 +0000, Vladimir Panteleev wrote:On Thursday, 12 February 2015 at 20:16:40 UTC, Walter Bright wrote:and as far as i know that never helps much. 'cause what people see is the=20 page with registration form, and chances are that they will stop right=20 there. and if someone is ready to register, i bet that he will find=20 bugzilla on his own. i.e. this may help some people, but don't much. and ldc and gdc will be=20 forced to patch that thing out. ;-)=Me, for example, I very very rarely bother to report a bug in a product I use. The reason isn't because I am lazy (although I am). It's because companies make it hard to report a bug. If they want to act like they're doing me a favor by accepting a bug report, then I won't bother.=20 Maybe print the Bugzilla URL on compiler ICEs? :) =20 I think gcc does that.
Feb 12 2015
On 2/12/2015 1:12 PM, Vladimir Panteleev wrote:On Thursday, 12 February 2015 at 20:16:40 UTC, Walter Bright wrote:Right on dlang.org under [Resources] there's [Bug Tracker]. I don't believe that's making it difficult to file a bug report.Me, for example, I very very rarely bother to report a bug in a product I use. The reason isn't because I am lazy (although I am). It's because companies make it hard to report a bug. If they want to act like they're doing me a favor by accepting a bug report, then I won't bother.Maybe print the Bugzilla URL on compiler ICEs? :) I think gcc does that.
Feb 12 2015
On 2015-02-12 23:29, Walter Bright wrote:Right on dlang.org under [Resources] there's [Bug Tracker]. I don't believe that's making it difficult to file a bug report.I had no idea that link existed :) -- /Jacob Carlborg
Feb 13 2015
On Thu, 12 Feb 2015 12:16:38 -0800, Walter Bright wrote:Why you did it doesn't matter. What matters is you did it and contributed it. Also, just because it wasn't reported before doesn't mean it wasn't happening to people. The vast majority will see a bug, and just dump the compiler and move to something else.that's exactly why i'm ashamed. 'cause i knew about this bug for almost a=20 year and a half, yet never tried to find out what was wrong until i have=20 to write some windows code, which was very uncomfortable to do in virtual=20 machine. i.e. i knew that the bug exists (but didn't know why) and don't=20 bothered to report it.Me, for example, I very very rarely bother to report a bug in a product I use. The reason isn't because I am lazy (although I am). It's because companies make it hard to report a bug. If they want to act like they're doing me a favor by accepting a bug report, then I won't bother.i may never agree on some bugreports, but i feel that D community is very=20 warm in accepting bug reports. and most of them either getting fixed, or=20 at least i'm told why they aren't a bugs. i mean that reporting bugs to D=20 bugzilla has the very visible effect, and it's great.=
Feb 12 2015
On 2/12/2015 1:21 PM, ketmar wrote:i may never agree on some bugreports, but i feel that D community is very warm in accepting bug reports. and most of them either getting fixed, or at least i'm told why they aren't a bugs. i mean that reporting bugs to D bugzilla has the very visible effect, and it's great.I agree. It's easy to report bugs, and we don't try and hide them.
Feb 12 2015
On Wednesday, 11 February 2015 at 18:53:41 UTC, H. S. Teoh wrote:But what's the use if I don't have kindle for viewing the results?You can find .mobi viewers online. Amazon provides some as well, I think.
Feb 11 2015
On 2/11/2015 2:15 PM, Vladimir Panteleev wrote:On Wednesday, 11 February 2015 at 18:53:41 UTC, H. S. Teoh wrote:1. I've seen Kindles at the pawn shop for $35. 2. Kindle apps are downloadable from Amazon for most platforms.But what's the use if I don't have kindle for viewing the results?You can find .mobi viewers online. Amazon provides some as well, I think.
Feb 11 2015
On 2/12/2015 3:51 AM, H. S. Teoh via Digitalmars-d wrote:On Wed, Feb 11, 2015 at 06:32:27PM +0000, Vladimir Panteleev via Digitalmars-d wrote:Amazon has free Kindle apps for several platforms.On Wednesday, 11 February 2015 at 18:30:13 UTC, H. S. Teoh wrote:But what's the use if I don't have kindle for viewing the results?but the fact that (1) I don't even have kindlegen,It's a free download. Not FOSS though, binary blob.
Feb 12 2015
On Tuesday, 10 February 2015 at 21:00:11 UTC, H. S. Teoh wrote:This PR: https://github.com/D-Programming-Language/phobos/pull/2973 introduces a code example with 2-space indentation, whereas the rest of Phobos and dlang.org uses 4-space indentation. I don't like this. It's inconsistent, and is detracting from the professional look of D. It's bad enough that we are inconsistent from one page to another, it's even worse that this PR introduces a style inconsistency within a *single* doc page. It makes D look amateurish and unprofessional. Walter's reason for this is that 4-space indentation makes it look bad on Kindle and other small-screen readers. Which is a good point, but it shouldn't be reason for inconsistent code style throughout dlang.org. If we decide that 4-space indentation is no good, then we should switch *wholesale* to whatever it is we deem good. We should not be introducing arbitrary style differences on an ad hoc basis. So, what will it be? What coding style should we use for official language docs? Should we use 4-space indentation or 2-space indentation? Should we reduce the maximum line length in code samples so that they don't look horribly on narrow-width readers? Or something else altogether? (Note also, that the code example in question is part of a ddoc'd unittest, which means it is also inconsistent with the rest of Phobos code. This is a smaller issue than inconsistency in public-facing docs, but nonetheless, it's an annoying one.) Tas a ruby dev, i'm fine with 2-space indentation and as a python dev i'm fine with 4-space indentation with 80 chars limit. no tabs please
Feb 13 2015