www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - Like Go/Rust, why not to have "func" keyword before function

reply "Alexey T." <aaa5500 ya.ru> writes:
Will be much easier to read Source, if func declarataion begins 
with keyword. "def" of "func". e.g.

func myName(params.....): typeOfResult;
or
func myName(params...) -> typeOfResult;

easier to read and PARSE. Next D version may allow--with 
compatability of old syntad (C like where typeOfResult is 1st id).
Jan 19 2015
next sibling parent reply ketmar via Digitalmars-d <digitalmars-d puremagic.com> writes:
On Mon, 19 Jan 2015 20:51:02 +0000
"Alexey T. via Digitalmars-d" <digitalmars-d puremagic.com> wrote:

 Will be much easier to read Source, if func declarataion begins=20
 with keyword. "def" of "func". e.g.
=20
 func myName(params.....): typeOfResult;
 or
 func myName(params...) -> typeOfResult;
=20
 easier to read and PARSE. Next D version may allow--with=20
 compatability of old syntad (C like where typeOfResult is 1st id).
maybe it's better to just stick with go/rust then? really, everybody knows where to download that compilers, yet they comes here and using D...
Jan 19 2015
parent reply "Alexey T." <aaa5500 ya.ru> writes:
Better that next D version (next MAJOR version) can support such
syntax. (Old syntax may be compatible too but "deprecated").

What developers think..
Jan 19 2015
next sibling parent reply "Jonathan Marler" <johnnymarler gmail.com> writes:
On Monday, 19 January 2015 at 21:06:40 UTC, Alexey T. wrote:
 Better that next D version (next MAJOR version) can support such
 syntax. (Old syntax may be compatible too but "deprecated").

 What developers think..
I have a feeling you might get some strong opposition to this idea *Brace Yourself*. However, I don't mind discussing new ideas. I'm not familiar enough with the syntax grammar to say for sure whether or not this would make it easier to parse the language. If it does, I wouldn't think it would make it much more simple. One question is how would you declare a function pointer? Current : void function() myfunction; YourIdea: func void function() myfunction; This seems a little odd/redundant. I suppose you could change the syntax to something like this: func void myfunction(); But then you wouldn't be able to know if that was a function pointer or a function declaration. I'll finish by saying that at first glance, I'm not sure if adding this extra keyword will help readability much. I've never really had problems distinguishing between functions and other things. That being said, maybe I've been programming in C-like languages too much so take that with a grain of salt.
Jan 19 2015
parent Walter Bright <newshound2 digitalmars.com> writes:
On 1/19/2015 1:23 PM, Jonathan Marler wrote:
 I'm not familiar enough
 with the syntax grammar to say for sure whether or not this would make it
easier
 to parse the language.
This idea is not going to make the parsing any better.
Jan 19 2015
prev sibling parent "deadalnix" <deadalnix gmail.com> writes:
On Monday, 19 January 2015 at 21:06:40 UTC, Alexey T. wrote:
 Better that next D version (next MAJOR version) can support such
 syntax. (Old syntax may be compatible too but "deprecated").

 What developers think..
That why not is a not a good enough reason to do it.
Jan 19 2015
prev sibling next sibling parent reply Andrei Alexandrescu <SeeWebsiteForEmail erdani.org> writes:
On 1/19/15 12:51 PM, Alexey T. wrote:
 Will be much easier to read Source, if func declarataion begins with
 keyword. "def" of "func". e.g.

 func myName(params.....): typeOfResult;
 or
 func myName(params...) -> typeOfResult;

 easier to read and PARSE. Next D version may allow--with compatability
 of old syntad (C like where typeOfResult is 1st id).
No. -- Andrei
Jan 19 2015
next sibling parent reply Ary Borenszweig <ary esperanto.org.ar> writes:
On 1/19/15 6:25 PM, Andrei Alexandrescu wrote:
 On 1/19/15 12:51 PM, Alexey T. wrote:
 Will be much easier to read Source, if func declarataion begins with
 keyword. "def" of "func". e.g.

 func myName(params.....): typeOfResult;
 or
 func myName(params...) -> typeOfResult;

 easier to read and PARSE. Next D version may allow--with compatability
 of old syntad (C like where typeOfResult is 1st id).
No. -- Andrei
How do you search for a function definition? In Ruby I search "def some_name" and I find it. In Go I can probably search "func some_name". In Rust, "fn some_name". Browsing some C code for Ruby I search with regex with "^some_name" because they have the convention of writing functions like this: return_type function_name(...) { } It works, but if you stop following that convention you are lost. So... how do you search for a function definition in D without an IDE?
Jan 19 2015
next sibling parent reply Andrei Alexandrescu <SeeWebsiteForEmail erdani.org> writes:
On 1/19/15 2:49 PM, Ary Borenszweig wrote:
 On 1/19/15 6:25 PM, Andrei Alexandrescu wrote:
 On 1/19/15 12:51 PM, Alexey T. wrote:
 Will be much easier to read Source, if func declarataion begins with
 keyword. "def" of "func". e.g.

 func myName(params.....): typeOfResult;
 or
 func myName(params...) -> typeOfResult;

 easier to read and PARSE. Next D version may allow--with compatability
 of old syntad (C like where typeOfResult is 1st id).
No. -- Andrei
How do you search for a function definition? In Ruby I search "def some_name" and I find it. In Go I can probably search "func some_name". In Rust, "fn some_name". Browsing some C code for Ruby I search with regex with "^some_name" because they have the convention of writing functions like this: return_type function_name(...) { } It works, but if you stop following that convention you are lost. So... how do you search for a function definition in D without an IDE?
I abandon D and switch to Ruby. -- Andrei
Jan 19 2015
next sibling parent "Dicebot" <public dicebot.lv> writes:
On Monday, 19 January 2015 at 22:54:04 UTC, Andrei Alexandrescu 
wrote:
 I abandon D and switch to Ruby. -- Andrei
You should make a front page announcement.
Jan 19 2015
prev sibling parent reply Ary Borenszweig <ary esperanto.org.ar> writes:
On 1/19/15 7:54 PM, Andrei Alexandrescu wrote:
 On 1/19/15 2:49 PM, Ary Borenszweig wrote:
 On 1/19/15 6:25 PM, Andrei Alexandrescu wrote:
 On 1/19/15 12:51 PM, Alexey T. wrote:
 Will be much easier to read Source, if func declarataion begins with
 keyword. "def" of "func". e.g.

 func myName(params.....): typeOfResult;
 or
 func myName(params...) -> typeOfResult;

 easier to read and PARSE. Next D version may allow--with compatability
 of old syntad (C like where typeOfResult is 1st id).
No. -- Andrei
How do you search for a function definition? In Ruby I search "def some_name" and I find it. In Go I can probably search "func some_name". In Rust, "fn some_name". Browsing some C code for Ruby I search with regex with "^some_name" because they have the convention of writing functions like this: return_type function_name(...) { } It works, but if you stop following that convention you are lost. So... how do you search for a function definition in D without an IDE?
I abandon D and switch to Ruby. -- Andrei
Thanks for the answer.
Jan 19 2015
parent reply Andrei Alexandrescu <SeeWebsiteForEmail erdani.org> writes:
On 1/19/15 3:43 PM, Ary Borenszweig wrote:
 On 1/19/15 7:54 PM, Andrei Alexandrescu wrote:
 On 1/19/15 2:49 PM, Ary Borenszweig wrote:
 On 1/19/15 6:25 PM, Andrei Alexandrescu wrote:
 On 1/19/15 12:51 PM, Alexey T. wrote:
 Will be much easier to read Source, if func declarataion begins with
 keyword. "def" of "func". e.g.

 func myName(params.....): typeOfResult;
 or
 func myName(params...) -> typeOfResult;

 easier to read and PARSE. Next D version may allow--with compatability
 of old syntad (C like where typeOfResult is 1st id).
No. -- Andrei
How do you search for a function definition? In Ruby I search "def some_name" and I find it. In Go I can probably search "func some_name". In Rust, "fn some_name". Browsing some C code for Ruby I search with regex with "^some_name" because they have the convention of writing functions like this: return_type function_name(...) { } It works, but if you stop following that convention you are lost. So... how do you search for a function definition in D without an IDE?
I abandon D and switch to Ruby. -- Andrei
Thanks for the answer.
"Tel maître, tel valet." -- Andrei
Jan 19 2015
parent "deadalnix" <deadalnix gmail.com> writes:
On Tuesday, 20 January 2015 at 03:12:52 UTC, Andrei Alexandrescu 
wrote:
 "Tel maître, tel valet." -- Andrei
Will ruby now park cars ?
Jan 19 2015
prev sibling next sibling parent reply "Brian Schott" <briancschott gmail.com> writes:
On Monday, 19 January 2015 at 22:49:41 UTC, Ary Borenszweig wrote:
 So... how do you search for a function definition in D without 
 an IDE?
Running `dscanner --help` prints this: --declaration | -d symbolName [sourceFiles sourceDirectories] Find the location where symbolName is declared. This should be more accurate than "grep". Searches the given files and directories, or the current working directory if none are specified.
Jan 19 2015
next sibling parent "weaselcat" <weaselcat gmail.com> writes:
On Tuesday, 20 January 2015 at 00:13:37 UTC, Brian Schott wrote:
 On Monday, 19 January 2015 at 22:49:41 UTC, Ary Borenszweig 
 wrote:
 So... how do you search for a function definition in D without 
 an IDE?
Running `dscanner --help` prints this: --declaration | -d symbolName [sourceFiles sourceDirectories] Find the location where symbolName is declared. This should be more accurate than "grep". Searches the given files and directories, or the current working directory if none are specified.
you posted this while I was reading the first page : ( guess I could add an addendum I don't think being able to find a function by grepping "func foo" is anywhere near a valid reason for adding this syntax. Programming languages should be made for humans to read, and having "func" just adds visual noise. ... *cough*function attributes
Jan 19 2015
prev sibling parent reply "Joakim" <dlang joakim.fea.st> writes:
On Tuesday, 20 January 2015 at 00:13:37 UTC, Brian Schott wrote:
 On Monday, 19 January 2015 at 22:49:41 UTC, Ary Borenszweig 
 wrote:
 So... how do you search for a function definition in D without 
 an IDE?
Running `dscanner --help` prints this: --declaration | -d symbolName [sourceFiles sourceDirectories] Find the location where symbolName is declared. This should be more accurate than "grep". Searches the given files and directories, or the current working directory if none are specified.
^^^^^ THIS! I agree with Ary that grep hits a lot of false positives and all the formatting tricks don't work with other people's code, plus I've never liked IDES. Dscanner's D declaration finder has become indispensable in the short time I've been using it, to the point where I dread going back to searching for C declarations and getting stuck with grep again.
Jan 20 2015
parent Danni Coy via Digitalmars-d <digitalmars-d puremagic.com> writes:
regular expression search FunctionName.*\{ or FunctionName.*$\s*\{
depending on brace style

On Wed, Jan 21, 2015 at 4:37 AM, Joakim via Digitalmars-d
<digitalmars-d puremagic.com> wrote:
 On Tuesday, 20 January 2015 at 00:13:37 UTC, Brian Schott wrote:
 On Monday, 19 January 2015 at 22:49:41 UTC, Ary Borenszweig wrote:
 So... how do you search for a function definition in D without an IDE?
Running `dscanner --help` prints this: --declaration | -d symbolName [sourceFiles sourceDirectories] Find the location where symbolName is declared. This should be more accurate than "grep". Searches the given files and directories, or the current working directory if none are specified.
^^^^^ THIS! I agree with Ary that grep hits a lot of false positives and all the formatting tricks don't work with other people's code, plus I've never liked IDES. Dscanner's D declaration finder has become indispensable in the short time I've been using it, to the point where I dread going back to searching for C declarations and getting stuck with grep again.
Jan 21 2015
prev sibling next sibling parent "weaselcat" <weaselcat gmail.com> writes:
On Monday, 19 January 2015 at 22:49:41 UTC, Ary Borenszweig wrote:
 On 1/19/15 6:25 PM, Andrei Alexandrescu wrote:
 On 1/19/15 12:51 PM, Alexey T. wrote:
 Will be much easier to read Source, if func declarataion 
 begins with
 keyword. "def" of "func". e.g.

 func myName(params.....): typeOfResult;
 or
 func myName(params...) -> typeOfResult;

 easier to read and PARSE. Next D version may allow--with 
 compatability
 of old syntad (C like where typeOfResult is 1st id).
No. -- Andrei
How do you search for a function definition? In Ruby I search "def some_name" and I find it. In Go I can probably search "func some_name". In Rust, "fn some_name". Browsing some C code for Ruby I search with regex with "^some_name" because they have the convention of writing functions like this: return_type function_name(...) { } It works, but if you stop following that convention you are lost. So... how do you search for a function definition in D without an IDE?
dscanner -d
Jan 19 2015
prev sibling next sibling parent reply Walter Bright <newshound2 digitalmars.com> writes:
On 1/19/2015 2:49 PM, Ary Borenszweig wrote:
 So... how do you search for a function definition in D without an IDE?
I do a text search for the name of the function. I've been programming in C, C++, and D for 30 years without an IDE. It never occurred to me that this was not doable :-)
Jan 19 2015
next sibling parent "H. S. Teoh via Digitalmars-d" <digitalmars-d puremagic.com> writes:
On Mon, Jan 19, 2015 at 04:17:08PM -0800, Walter Bright via Digitalmars-d wrote:
 On 1/19/2015 2:49 PM, Ary Borenszweig wrote:
So... how do you search for a function definition in D without an
IDE?
I do a text search for the name of the function. I've been programming in C, C++, and D for 30 years without an IDE. It never occurred to me that this was not doable :-)
Me too(tm), for 20 years. T -- It is not the employer who pays the wages. Employers only handle the money. It is the customer who pays the wages. -- Henry Ford
Jan 19 2015
prev sibling next sibling parent reply Ary Borenszweig <ary esperanto.org.ar> writes:
On 1/19/15 9:17 PM, Walter Bright wrote:
 On 1/19/2015 2:49 PM, Ary Borenszweig wrote:
 So... how do you search for a function definition in D without an IDE?
I do a text search for the name of the function. I've been programming in C, C++, and D for 30 years without an IDE. It never occurred to me that this was not doable :-)
But the results will also contain invocations of that function. Do you go one by one until you find the definition?
Jan 19 2015
next sibling parent "Jon" <x x.com> writes:
On Tuesday, 20 January 2015 at 01:35:17 UTC, Ary Borenszweig 
wrote:
 On 1/19/15 9:17 PM, Walter Bright wrote:
 On 1/19/2015 2:49 PM, Ary Borenszweig wrote:
 So... how do you search for a function definition in D 
 without an IDE?
I do a text search for the name of the function. I've been programming in C, C++, and D for 30 years without an IDE. It never occurred to me that this was not doable :-)
But the results will also contain invocations of that function. Do you go one by one until you find the definition?
Sure. If it is a very commonly-used function (like a library function), the definition is probably in a different file from the one most of the invocations are in anyhow. -Jon
Jan 19 2015
prev sibling next sibling parent "Vlad Levenfeld" <vlevenfeld gmail.com> writes:
On Tuesday, 20 January 2015 at 01:35:17 UTC, Ary Borenszweig
wrote:
 On 1/19/15 9:17 PM, Walter Bright wrote:
 On 1/19/2015 2:49 PM, Ary Borenszweig wrote:
 So... how do you search for a function definition in D 
 without an IDE?
I do a text search for the name of the function. I've been programming in C, C++, and D for 30 years without an IDE. It never occurred to me that this was not doable :-)
But the results will also contain invocations of that function. Do you go one by one until you find the definition?
First instance of function name preceding an open brace following a closed paren before a semicolon. Its a mouthful but the regex isn't that complex if you are comfortable with lookahead/behind
Jan 19 2015
prev sibling next sibling parent reply Walter Bright <newshound2 digitalmars.com> writes:
On 1/19/2015 5:35 PM, Ary Borenszweig wrote:
 On 1/19/15 9:17 PM, Walter Bright wrote:
 On 1/19/2015 2:49 PM, Ary Borenszweig wrote:
 So... how do you search for a function definition in D without an IDE?
I do a text search for the name of the function. I've been programming in C, C++, and D for 30 years without an IDE. It never occurred to me that this was not doable :-)
But the results will also contain invocations of that function. Do you go one by one until you find the definition?
Yes. "Search Again" is a single button press. It really has never occurred to me that this might be a problem needing a solution. Of course, I'm careful not to name my functions "the".
Jan 19 2015
parent reply Walter Bright <newshound2 digitalmars.com> writes:
On 1/19/2015 7:20 PM, Walter Bright wrote:
 Yes. "Search Again" is a single button press. It really has never occurred to
me
 that this might be a problem needing a solution.
I admit that I've never gotten in to using an IDE. I still have complaints about the programmer's editor I use, but they aren't big enough to motivate me to fix it! The nice thing about my editor is it works exactly the same on: Windows Linux FreeBSD OSX in a remote tty text window and is small enough to load instantly.
Jan 19 2015
parent reply "Jonathan Marler" <johnnymarler gmail.com> writes:
On Tuesday, 20 January 2015 at 03:28:29 UTC, Walter Bright wrote:
 On 1/19/2015 7:20 PM, Walter Bright wrote:
 Yes. "Search Again" is a single button press. It really has 
 never occurred to me
 that this might be a problem needing a solution.
I admit that I've never gotten in to using an IDE. I still have complaints about the programmer's editor I use, but they aren't big enough to motivate me to fix it! The nice thing about my editor is it works exactly the same on: Windows Linux FreeBSD OSX in a remote tty text window and is small enough to load instantly.
Which editor do you use? I use emacs. It has some quirks. The D-Mode doesn't work very well (I end up using Notepad++ when working on phobos/druntime), but I can use it on every platform and over a remote tty so I deal with its imperfections.
Jan 20 2015
next sibling parent ketmar via Digitalmars-d <digitalmars-d puremagic.com> writes:
On Tue, 20 Jan 2015 20:30:00 +0000
Jonathan Marler via Digitalmars-d <digitalmars-d puremagic.com> wrote:

 On Tuesday, 20 January 2015 at 03:28:29 UTC, Walter Bright wrote:
 On 1/19/2015 7:20 PM, Walter Bright wrote:
 Yes. "Search Again" is a single button press. It really has=20
 never occurred to me
 that this might be a problem needing a solution.
I admit that I've never gotten in to using an IDE. I still have=20 complaints about the programmer's editor I use, but they aren't=20 big enough to motivate me to fix it! The nice thing about my editor is it works exactly the same on: Windows Linux FreeBSD OSX in a remote tty text window and is small enough to load instantly.
=20 Which editor do you use? I use emacs. It has some quirks. The=20 D-Mode doesn't work very well (I end up using Notepad++ when=20 working on phobos/druntime), but I can use it on every platform=20 and over a remote tty so I deal with its imperfections.
might it be microemacs from Digital Mars site? ;-)
Jan 20 2015
prev sibling next sibling parent Walter Bright <newshound2 digitalmars.com> writes:
On 1/20/2015 12:30 PM, Jonathan Marler wrote:
 Which editor do you use?
https://github.com/DigitalMars/me
Jan 20 2015
prev sibling parent reply Russel Winder via Digitalmars-d <digitalmars-d puremagic.com> writes:
On Tue, 2015-01-20 at 20:30 +0000, Jonathan Marler via Digitalmars-d
wrote:
[=E2=80=A6]
 Which editor do you use?  I use emacs.  It has some quirks.  The=20
 D-Mode doesn't work very well (I end up using Notepad++ when=20
 working on phobos/druntime), but I can use it on every platform=20
 and over a remote tty so I deal with its imperfections.
The Emacs D-Mode will only improve if people provide bug reports and fixes. A number of people are doing this for their "pain points". If the Emacs D-Mode is substandard for you, can you at least submit issues presenting the problems. --=20 Russel. =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D Dr Russel Winder t: +44 20 7585 2200 voip: sip:russel.winder ekiga.n= et 41 Buckmaster Road m: +44 7770 465 077 xmpp: russel winder.org.uk London SW11 1EN, UK w: www.russel.org.uk skype: russel_winder
Jan 21 2015
parent reply Walter Bright <newshound2 digitalmars.com> writes:
On 1/21/2015 12:19 AM, Russel Winder via Digitalmars-d wrote:
 The Emacs D-Mode will only improve if people provide bug reports and
 fixes. A number of people are doing this for their "pain points". If the
 Emacs D-Mode is substandard for you, can you at least submit issues
 presenting the problems.
I wonder why software companies still make it impossible to submit bug reports. For example, google: "submit windows movie maker bug report" Click on "Reporting and solving computer problems - Windows": http://windows.microsoft.com/en-us/windows-vista/reporting-and-solving-computer-problems Note that there is actually no way to report a problem to Microsoft, in spite of what the headings say. I find this utterly baffling. Why make it so difficult to report a bug? Microsoft has always been like this, the only way I've ever been able to submit a bug report was if I had a friend on the inside who'd carry it in for me. This is probably why Windows Movie Maker is such a buggy program. It hangs constantly, generates corrupt files when creating a movie file longer than 2G (about 2 hours), etc.
Jan 21 2015
next sibling parent reply Russel Winder via Digitalmars-d <digitalmars-d puremagic.com> writes:
Whereas for Emacs D-Mode you rock up to=20

https://github.com/Emacs-D-Mode-Maintainers/Emacs-D-Mode/issues


and post. There is no guarantee of action though since there is no-one
paid to do support, it's all volunteer activity. However a number of
people do hack on the ELisp and fix things.

All commits to the mainline end up with a new release to MELPA, so
anyone using Emacs 24 or later with package management has the most
up-to-date D-Mode.

--=20
Russel.
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D
Dr Russel Winder      t: +44 20 7585 2200   voip: sip:russel.winder ekiga.n=
et
41 Buckmaster Road    m: +44 7770 465 077   xmpp: russel winder.org.uk
London SW11 1EN, UK   w: www.russel.org.uk  skype: russel_winder
Jan 21 2015
parent Walter Bright <newshound2 digitalmars.com> writes:
On 1/21/2015 12:59 AM, Russel Winder via Digitalmars-d wrote:
 Whereas for Emacs D-Mode you rock up to

 https://github.com/Emacs-D-Mode-Maintainers/Emacs-D-Mode/issues


 and post. There is no guarantee of action though since there is no-one
 paid to do support, it's all volunteer activity. However a number of
 people do hack on the ELisp and fix things.
And that's the way to do it!
Jan 21 2015
prev sibling next sibling parent reply "Joakim" <dlang joakim.fea.st> writes:
On Wednesday, 21 January 2015 at 08:41:47 UTC, Walter Bright 
wrote:
 On 1/21/2015 12:19 AM, Russel Winder via Digitalmars-d wrote:
 The Emacs D-Mode will only improve if people provide bug 
 reports and
 fixes. A number of people are doing this for their "pain 
 points". If the
 Emacs D-Mode is substandard for you, can you at least submit 
 issues
 presenting the problems.
I wonder why software companies still make it impossible to submit bug reports. For example, google: "submit windows movie maker bug report" Click on "Reporting and solving computer problems - Windows": http://windows.microsoft.com/en-us/windows-vista/reporting-and-solving-computer-problems Note that there is actually no way to report a problem to Microsoft, in spite of what the headings say.
Heh, considering Bill Gates couldn't even figure out how to _download_ Movie Maker a decade ago, you're way ahead of the game: ;) http://blog.seattlepi.com/microsoft/2008/06/24/full-text-an-epic-bill-gates-e-mail-rant/
 I find this utterly baffling. Why make it so difficult to 
 report a bug? Microsoft has always been like this, the only way 
 I've ever been able to submit a bug report was if I had a 
 friend on the inside who'd carry it in for me.

 This is probably why Windows Movie Maker is such a buggy 
 program. It hangs constantly, generates corrupt files when 
 creating a movie file longer than 2G (about 2 hours), etc.
Probably because Microsoft has so many millions of users that their bug tracker would be awash with noise. Google allows anybody with a google account to post bugs or comment on them for Chrome and Android, which has led to a ton of noise on their public bug trackers, along with the benefit of a bunch of bug reports they'd otherwise never have gotten: https://code.google.com/p/chromium/issues/list https://code.google.com/p/android/issues/list Is it worth the tradeoff? Maybe not for them, considering the many untriaged bugs on their trackers, which they haven't bothered putting somebody on filtering.
Jan 21 2015
next sibling parent Walter Bright <newshound2 digitalmars.com> writes:
On 1/21/2015 1:14 AM, Joakim wrote:
 Probably because Microsoft has so many millions of users that their bug tracker
 would be awash with noise.  Google allows anybody with a google account to post
 bugs or comment on them for Chrome and Android, which has led to a ton of noise
 on their public bug trackers, along with the benefit of a bunch of bug reports
 they'd otherwise never have gotten:

 https://code.google.com/p/chromium/issues/list
 https://code.google.com/p/android/issues/list

 Is it worth the tradeoff?  Maybe not for them, considering the many untriaged
 bugs on their trackers, which they haven't bothered putting somebody on
filtering.
I don't see how Microsoft can afford to miss those important reports. Sure, there'll be a lot of noise, but you just put someone on there to filter them. And besides, with all the vaunted machine intelligence we've been hearing about lately, surely some sort of automated filter could be devised. For example, one could automatically filter out borderline illiterate submissions, and close duplicates. Or one could make it a public tracker, and let the crowd filter them, sort of like reddit.
Jan 21 2015
prev sibling parent reply Andrei Alexandrescu <SeeWebsiteForEmail erdani.org> writes:
On 1/21/15 1:14 AM, Joakim wrote:
 On Wednesday, 21 January 2015 at 08:41:47 UTC, Walter Bright wrote:
 On 1/21/2015 12:19 AM, Russel Winder via Digitalmars-d wrote:
 The Emacs D-Mode will only improve if people provide bug reports and
 fixes. A number of people are doing this for their "pain points". If the
 Emacs D-Mode is substandard for you, can you at least submit issues
 presenting the problems.
I wonder why software companies still make it impossible to submit bug reports. For example, google: "submit windows movie maker bug report" Click on "Reporting and solving computer problems - Windows": http://windows.microsoft.com/en-us/windows-vista/reporting-and-solving-computer-problems Note that there is actually no way to report a problem to Microsoft, in spite of what the headings say.
Heh, considering Bill Gates couldn't even figure out how to _download_ Movie Maker a decade ago, you're way ahead of the game: ;) http://blog.seattlepi.com/microsoft/2008/06/24/full-text-an-epic-bill-gates-e-mail-rant/
Yah, that's a good read. FWIW the right answer here is to vote with one's feet - there's plenty of video processing software in the free world.
 I find this utterly baffling. Why make it so difficult to report a
 bug? Microsoft has always been like this, the only way I've ever been
 able to submit a bug report was if I had a friend on the inside who'd
 carry it in for me.

 This is probably why Windows Movie Maker is such a buggy program. It
 hangs constantly, generates corrupt files when creating a movie file
 longer than 2G (about 2 hours), etc.
Probably because Microsoft has so many millions of users that their bug tracker would be awash with noise.
Even better. At Facebook we use statistics and machine learning to derive excellent signal from large inputs. Andrei
Jan 21 2015
parent reply Walter Bright <newshound2 digitalmars.com> writes:
On 1/21/2015 7:40 AM, Andrei Alexandrescu wrote:
 there's plenty of video processing software in the free world.
About 10 years ago, I needed to edit a movie. I downloaded about 10 different video editors. Every one would hang, crash, go berserk, generate corrupt files, etc. I didn't do anything clever, just to trim, cut and paste. I never even bothered to try anything more advanced. I eventually gave up and did the editing with a standalone dvd recorder. It left such bad taste I was unwilling to try it again until recently. I'm disgusted that the problems remain. How hard can it be?
Jan 21 2015
next sibling parent "H. S. Teoh via Digitalmars-d" <digitalmars-d puremagic.com> writes:
On Wed, Jan 21, 2015 at 10:45:26AM -0800, Walter Bright via Digitalmars-d wrote:
 On 1/21/2015 7:40 AM, Andrei Alexandrescu wrote:
there's plenty of video processing software in the free world.
About 10 years ago, I needed to edit a movie. I downloaded about 10 different video editors. Every one would hang, crash, go berserk, generate corrupt files, etc. I didn't do anything clever, just to trim, cut and paste. I never even bothered to try anything more advanced. I eventually gave up and did the editing with a standalone dvd recorder. It left such bad taste I was unwilling to try it again until recently. I'm disgusted that the problems remain. How hard can it be?
Maybe you should write a superior video editor in D. :-) That might be the killer app D has been waiting for. :-P T -- Those who don't understand D are condemned to reinvent it, poorly. -- Daniel N
Jan 21 2015
prev sibling parent reply Andrei Alexandrescu <SeeWebsiteForEmail erdani.org> writes:
On 1/21/15 10:45 AM, Walter Bright wrote:
 On 1/21/2015 7:40 AM, Andrei Alexandrescu wrote:
 there's plenty of video processing software in the free world.
About 10 years ago, I needed to edit a movie. I downloaded about 10 different video editors. Every one would hang, crash, go berserk, generate corrupt files, etc. I didn't do anything clever, just to trim, cut and paste. I never even bothered to try anything more advanced. I eventually gave up and did the editing with a standalone dvd recorder. It left such bad taste I was unwilling to try it again until recently. I'm disgusted that the problems remain. How hard can it be?
"10 years is a long time" -- Andrei
Jan 21 2015
next sibling parent reply Brad Roberts via Digitalmars-d <digitalmars-d puremagic.com> writes:
On 1/21/2015 10:53 AM, Andrei Alexandrescu via Digitalmars-d wrote:
 On 1/21/15 10:45 AM, Walter Bright wrote:
 On 1/21/2015 7:40 AM, Andrei Alexandrescu wrote:
 there's plenty of video processing software in the free world.
About 10 years ago, I needed to edit a movie. I downloaded about 10 different video editors. Every one would hang, crash, go berserk, generate corrupt files, etc. I didn't do anything clever, just to trim, cut and paste. I never even bothered to try anything more advanced. I eventually gave up and did the editing with a standalone dvd recorder. It left such bad taste I was unwilling to try it again until recently. I'm disgusted that the problems remain. How hard can it be?
"10 years is a long time" -- Andrei
I'll note, for what it's worth, that there's open bug reports against D that are almost 9 years old... oldest open bug was filed in May of 2006. Some of them fairly fundamental.
Jan 21 2015
parent Walter Bright <newshound2 digitalmars.com> writes:
On 1/21/2015 11:03 AM, Brad Roberts via Digitalmars-d wrote:
 I'll note, for what it's worth, that there's open bug reports against D that
are
 almost 9 years old... oldest open bug was filed in May of 2006.  Some of them
 fairly fundamental.
All software has bugs. But trimming a video is the most basic operation one would like to use a video editor for, and there's no workaround for it not working.
Jan 21 2015
prev sibling parent Walter Bright <newshound2 digitalmars.com> writes:
On 1/21/2015 10:53 AM, Andrei Alexandrescu wrote:
 On 1/21/15 10:45 AM, Walter Bright wrote:
 It left such bad taste I was unwilling to try it again until recently.
 I'm disgusted that the problems remain. How hard can it be?
"10 years is a long time" -- Andrei
Right, which is why I'm disgusted that I still cannot trim the left and right edges off.
Jan 21 2015
prev sibling next sibling parent reply ketmar via Digitalmars-d <digitalmars-d puremagic.com> writes:
On Wed, 21 Jan 2015 00:40:48 -0800
Walter Bright via Digitalmars-d <digitalmars-d puremagic.com> wrote:

 I find this utterly baffling. Why make it so difficult to report a bug?=20
 Microsoft has always been like this, the only way I've ever been able to =
submit=20
 a bug report was if I had a friend on the inside who'd carry it in for me.
=20
 This is probably why Windows Movie Maker is such a buggy program. It hang=
s=20
 constantly, generates corrupt files when creating a movie file longer tha=
n 2G=20
 (about 2 hours), etc.
if they will allow public bugreports, they will have zillions "bugreports" like "i pressed that button and it doesn't do that!" -- literally. and they will need to hire special man who will be able to sort that bugreports. and he should be developer himself to see if that report can be used or must be moved to /dev/null. and... this simply not work. and not worth it.
Jan 21 2015
parent reply Walter Bright <newshound2 digitalmars.com> writes:
On 1/21/2015 8:23 AM, ketmar via Digitalmars-d wrote:
 this simply not work.
Neither does Windows Moviemaker. It hung again on me.
 and not worth it.
WMM is over a decade old, and it still hangs doing something as simple as trimming off the start and the end. And not rarely, either. It does it constantly. Why even ship such a product you have no intention of fixing bugs for? It's a net negative for one's image.
Jan 21 2015
next sibling parent ketmar via Digitalmars-d <digitalmars-d puremagic.com> writes:
On Wed, 21 Jan 2015 10:39:14 -0800
Walter Bright via Digitalmars-d <digitalmars-d puremagic.com> wrote:

 Why even ship such a product you have no intention of fixing bugs for? It=
's a=20
 net negative for one's image.
ah, that's a different question! i don't know why they still shipping it instead of providing link to virtualdub, for example.
Jan 21 2015
prev sibling parent reply Steven Schveighoffer <schveiguy yahoo.com> writes:
On 1/21/15 1:39 PM, Walter Bright wrote:
 On 1/21/2015 8:23 AM, ketmar via Digitalmars-d wrote:
 this simply not work.
Neither does Windows Moviemaker. It hung again on me.
Just FYI iMovie works just fine ;)
 and not worth it.
WMM is over a decade old, and it still hangs doing something as simple as trimming off the start and the end. And not rarely, either. It does it constantly.
This is pretty bad. I remember in college we had a "movie lab" which had lots of hi-end PCs running NT 4.0, with, among other things, 3D-studio max. In the 3d-graphics class I took, one of our assignments was to use 3DSM to animate something with certain requirements. The thing crashed so frequently that several students made 3d-animations focused on how horrible 3DSM was :) When software you are using that is supposed to make things easier gets in the way, you may as well not use it.
 Why even ship such a product you have no intention of fixing bugs for?
 It's a net negative for one's image.
I wonder if it's for a bullet point. I know my sister-in-law has made videos with WMM (and she is NOT a techie), but they were simple movies. Perhaps if you want to do anything super-involved, it's not ready for the job. Also, in one company I worked for, we had a paid contract with Microsoft for fixing bugs. I worked for months with them on a bug in one of their advanced server systems. In the end, they narrowed it down to the fact that the system required MSSQL express (not full version), which only worked with a shared-memory interface. Something in their server just didn't work right. So we had to install full-blown MSSQL which was configured only to use network connection. Then in about 6 months they discontinued that advanced server product. Then I rewrote the whole thing in Linux ;) Sometimes I wonder if Microsoft is simply a marketing arm of other OSes... But I am surprised MS does not have some way to get reasonable paid support for their software. Apple gives you 1 year free software/hardware support when you buy a Mac. I can fully understand not offering "Free" support. Not everyone is a Walter Bright. -Steve
Jan 22 2015
parent reply Walter Bright <newshound2 digitalmars.com> writes:
On 1/22/2015 4:44 AM, Steven Schveighoffer wrote:
 But I am surprised MS does not have some way to get reasonable paid support for
 their software. Apple gives you 1 year free software/hardware support when you
 buy a Mac. I can fully understand not offering "Free" support. Not everyone is
a
 Walter Bright.
I wasn't expecting support. Just a way to submit a bug report!
Jan 22 2015
parent Steven Schveighoffer <schveiguy yahoo.com> writes:
On 1/22/15 12:03 PM, Walter Bright wrote:
 On 1/22/2015 4:44 AM, Steven Schveighoffer wrote:
 But I am surprised MS does not have some way to get reasonable paid
 support for
 their software. Apple gives you 1 year free software/hardware support
 when you
 buy a Mac. I can fully understand not offering "Free" support. Not
 everyone is a
 Walter Bright.
I wasn't expecting support. Just a way to submit a bug report!
So you didn't want it to be fixed? ;) -Steve
Jan 22 2015
prev sibling parent "Kagamin" <spam here.lot> writes:
On Wednesday, 21 January 2015 at 08:41:47 UTC, Walter Bright 
wrote:
 I wonder why software companies still make it impossible to 
 submit bug reports. For example, google:

 "submit windows movie maker bug report"

 Click on "Reporting and solving computer problems - Windows":

 http://windows.microsoft.com/en-us/windows-vista/reporting-and-solving-computer-problems

 Note that there is actually no way to report a problem to 
 Microsoft, in spite of what the headings say.
support microsoft.com? Just a wild guess.
Jan 22 2015
prev sibling next sibling parent Steven Schveighoffer <schveiguy yahoo.com> writes:
On 1/19/15 8:35 PM, Ary Borenszweig wrote:
 On 1/19/15 9:17 PM, Walter Bright wrote:
 On 1/19/2015 2:49 PM, Ary Borenszweig wrote:
 So... how do you search for a function definition in D without an IDE?
I do a text search for the name of the function. I've been programming in C, C++, and D for 30 years without an IDE. It never occurred to me that this was not doable :-)
But the results will also contain invocations of that function. Do you go one by one until you find the definition?
Yep. Do it all the time. It's not that hard to see the difference between a definition and usage. -Steve
Jan 20 2015
prev sibling parent reply ketmar via Digitalmars-d <digitalmars-d puremagic.com> writes:
On Mon, 19 Jan 2015 22:35:16 -0300
Ary Borenszweig via Digitalmars-d <digitalmars-d puremagic.com> wrote:

 On 1/19/15 9:17 PM, Walter Bright wrote:
 On 1/19/2015 2:49 PM, Ary Borenszweig wrote:
 So... how do you search for a function definition in D without an IDE?
I do a text search for the name of the function. I've been programming in C, C++, and D for 30 years without an IDE. It never occurred to me that this was not doable :-)
=20 But the results will also contain invocations of that function. Do you=20 go one by one until you find the definition?
heh. void function foo () { ... } foo(); do you see the subtle difference? yes, that tiny whitespace in declaration. i borrowed that habit from some Oberon code decades ago, and it serves me well since then.
Jan 20 2015
parent reply "MattCoder" <stop spam.com> writes:
On Tuesday, 20 January 2015 at 13:47:11 UTC, ketmar via 
Digitalmars-d wrote:
   void function foo () { ... }
   foo();

 do you see the subtle difference? yes, that tiny whitespace in
 declaration. i borrowed that habit from some Oberon code 
 decades ago, and it serves me well since then.
Hmm, nice one. I think I'll do this too. Matheus.
Jan 20 2015
parent ketmar via Digitalmars-d <digitalmars-d puremagic.com> writes:
On Tue, 20 Jan 2015 13:49:47 +0000
MattCoder via Digitalmars-d <digitalmars-d puremagic.com> wrote:

 On Tuesday, 20 January 2015 at 13:47:11 UTC, ketmar via=20
 Digitalmars-d wrote:
   void function foo () { ... }
   foo();

 do you see the subtle difference? yes, that tiny whitespace in
 declaration. i borrowed that habit from some Oberon code=20
 decades ago, and it serves me well since then.
=20 Hmm, nice one. I think I'll do this too.
be my guest. ;-) i'll be glad if it will help you. the only bad thing i found with this style is that after some time you really start noticing the absense of whitespace in declaraions, and it annoys you. so the first thing you want to do with someone's code is to ADD THAT WHITESPACES! somehow it becomes most frustrating element of alien code styling. ;-)
Jan 20 2015
prev sibling parent Rikki Cattermole <alphaglosined gmail.com> writes:
On 20/01/2015 1:17 p.m., Walter Bright wrote:
 On 1/19/2015 2:49 PM, Ary Borenszweig wrote:
 So... how do you search for a function definition in D without an IDE?
I do a text search for the name of the function. I've been programming in C, C++, and D for 30 years without an IDE. It never occurred to me that this was not doable :-)
I've only been programming for 8 years on and off IDE's. And I must say, even I do the old search for function names even when in an IDE! Thanks MonoD and friends! You do great on the searching! I'm not really complaining. Once we have Intellij IDEA plugin fully working, these problems will go away altogether. Since it cache's AST and bunch of other nice tricks.
Jan 19 2015
prev sibling next sibling parent Mike Parker <aldacron gmail.com> writes:
On 1/20/2015 7:49 AM, Ary Borenszweig wrote:

 It works, but if you stop following that convention you are lost.

 So... how do you search for a function definition in D without an IDE?
Case-insensitive search on "funcname(" usually works for me.
Jan 19 2015
prev sibling parent Danni Coy via Digitalmars-d <digitalmars-d puremagic.com> writes:
 So... how do you search for a function definition in D without an IDE?
Regular Expression Search for FunctionName.*\n\s*\{ or FunctionName.*\{ depending on brace style being used.
Jan 20 2015
prev sibling parent "Israel" <tl12000 live.com> writes:
On Monday, 19 January 2015 at 21:25:16 UTC, Andrei Alexandrescu
wrote:
 On 1/19/15 12:51 PM, Alexey T. wrote:
 Will be much easier to read Source, if func declarataion 
 begins with
 keyword. "def" of "func". e.g.

 func myName(params.....): typeOfResult;
 or
 func myName(params...) -> typeOfResult;

 easier to read and PARSE. Next D version may allow--with 
 compatability
 of old syntad (C like where typeOfResult is 1st id).
No. -- Andrei
LOL. That reply...
Jan 19 2015
prev sibling next sibling parent "bachmeier" <no spam.com> writes:
On Monday, 19 January 2015 at 20:51:03 UTC, Alexey T. wrote:
 Will be much easier to read Source, if func declarataion begins 
 with keyword. "def" of "func". e.g.

 func myName(params.....): typeOfResult;
 or
 func myName(params...) -> typeOfResult;

 easier to read and PARSE. Next D version may allow--with 
 compatability of old syntad (C like where typeOfResult is 1st 
 id).
I have nothing against Rust, but that's the last place I'd go if I were looking for improved syntax. Personally I view it as visual clutter that will make it harder to read the program.
Jan 19 2015
prev sibling next sibling parent reply Jonathan M Davis via Digitalmars-d <digitalmars-d puremagic.com> writes:
On Monday, January 19, 2015 20:51:02 Alexey T. via Digitalmars-d wrote:
 Will be much easier to read Source, if func declarataion begins
 with keyword. "def" of "func". e.g.

 func myName(params.....): typeOfResult;
 or
 func myName(params...) -> typeOfResult;

 easier to read and PARSE. Next D version may allow--with
 compatability of old syntad (C like where typeOfResult is 1st id).
I don't recall ever having any problem with the C/C++ syntax that D uses. The major problem was with the function pointer syntax, and we already fixed that. I really don't see how changing the function signature syntax in D would help anything, and it would force all existing code to be changed (be it immediately or just when the compatability flag finally goes anyway). Sometimes, syntax improvements are worth it, but in general, it's just not worth messing with the syntax unless the language is still in flux enough that you don't care at all about breaking existing code. So, even if your suggestion were objectively better (and it really isn't), we probably wouldn't go with it at this point. - Jonathan M Davis
Jan 19 2015
parent reply "Alexey T." <aaa5500 ya.ru> writes:
Ok I see your arguments, indeed, breaking masss of code isn't 
good (even with deprecated flag).
So leave it as is (it is TOO LATE to change this)
Jan 19 2015
parent reply "ponce" <contact gam3sfrommars.fr> writes:
On Monday, 19 January 2015 at 22:18:34 UTC, Alexey T. wrote:
 Ok I see your arguments, indeed, breaking masss of code isn't 
 good (even with deprecated flag).
 So leave it as is (it is TOO LATE to change this)
Current syntax is akin to C and C++, it means many people already read it visually and it is easier to port C code to D.
Jan 19 2015
parent reply Walter Bright <newshound2 digitalmars.com> writes:
On 1/19/2015 2:51 PM, ponce wrote:
 Current syntax is akin to C and C++, it means many people already read it
 visually and it is easier to port C code to D.
Bingo. It's designed to be an easy transition for people used to programming in C, C++ and Java.
Jan 19 2015
parent Jonathan M Davis via Digitalmars-d <digitalmars-d puremagic.com> writes:
On Monday, January 19, 2015 16:18:25 Walter Bright via Digitalmars-d wrote:
 On 1/19/2015 2:51 PM, ponce wrote:
 Current syntax is akin to C and C++, it means many people already read it
 visually and it is easier to port C code to D.
Bingo. It's designed to be an easy transition for people used to programming in C, C++ and Java.
That and the fact that most of the folks working on the language have been programming in C, C++, etc. for years, and it probably never occurred to most of them to have a different function declaration syntax in the first place. Even if there's a better way to do something, if it never occurs to you that there's anything wrong with the current way, you're not going to come up with a new one. - Jonathan M Davis
Jan 19 2015
prev sibling parent "Kagamin" <spam here.lot> writes:
On Monday, 19 January 2015 at 20:51:03 UTC, Alexey T. wrote:
 Will be much easier to read Source, if func declarataion begins 
 with keyword. "def" of "func". e.g.

 func myName(params.....): typeOfResult;
 or
 func myName(params...) -> typeOfResult;

 easier to read and PARSE. Next D version may allow--with 
 compatability of old syntad (C like where typeOfResult is 1st 
 id).
Why reinvent pascal, but worse? Just go with it: http://freepascal.org/
Jan 20 2015