On 06/07/2015 10:28 PM, Daniel Schürmann wrote:
> Hi,
>
> I think we use always the copy-initialization for pod types inside Mixxx
Sure? I don't currently recall what the compiler has to do if we
explicitly define a copy constructor, is the copy or implicitly
generated move constructor used? F
Hi,
I think we use always the copy-initialization for pod types inside Mixxx
(Except initializations lists)
int value = 4;
For me this is the best readable version and is exactly what the underlying
machine code does.
The value 4 is copied from the text segment to a cpu register.
Now we have the
On 06/06/2015 11:24 AM, Uwe Klotz wrote:
> +1 Gavin, I also prefer direct-initialization over copy-initialization.
>
> For classes without a copy constructor you need to use
> direct-initialization anyway. And if you bravely declare your single
> parameter constructors as 'explicit' (what you sho
+1 Gavin, I also prefer direct-initialization over copy-initialization.
For classes without a copy constructor you need to use direct-initialization
anyway. And if you bravely declare your single parameter constructors as
'explicit' (what you should almost always do, even if Qt does not) you al
On another note. I have not seen a c++ ide, that's not super expensive,
that can provide the type of refactoring support java does.
On Sat, Jun 6, 2015, 5:01 AM Musikpirat wrote:
> Am 06.06.2015 um 10:53 schrieb Gavin Swanson:
> > I have three. This doesn't actually tell you anything about type,
Am 06.06.2015 um 10:53 schrieb Gavin Swanson:
> I have three. This doesn't actually tell you anything about type, and
> requires less code change later when that simple type becomes a complex
> type.
If a simple type becomes a complex type you usually do something else
with it than before. So ther
I have three. This doesn't actually tell you anything about type, and
requires less code change later when that simple type becomes a complex
type. Why rely on the compiler to perform an optimization that it has no
obligation to perform?
Honestly whatever the project feels is best, but document it
Hi,
Am 05.06.2015 um 22:44 schrieb Owen Williams:
> On Fri, 2015-06-05 at 22:30 +0200, Daniel Schürmann wrote:
>
>> CSAMPLE sample = 0.0;
>
> This one. auto should really only be used when assigning from a
> function whose return value is obvious.
What is the advantage of not knowing what kind
In a project the size of mixxx (at least as they come up) every situation
should be enumerated and documented (to the extent possible in an os
project). This provides new developers the information to maintain
consistency. The code, especially in a large project that hasn't had the
formatting enfor
Well my thinking is more aimed at humans reading code than the compiler
reading it. The function-style initialization looks like a class
initialization, which makes CSAMPLE look heavier than it is. What I've
been taught is that what's most important is the syntactic clues that a
reader picks up a
are we in violent agreement then? Why not do the optimal thing in the first
place for consistency sake? Rather than rely on the compiler to do it for
you. Especially in a case like this where the optimization is no more work
nor is it less readable.
On Fri, Jun 5, 2015, 7:38 PM Owen Williams wro
That's what I said?
"The compiler is free to elide (remove) the temporary+copying whenever
it can, but copy constructor must still be accessible"
On Fri, 2015-06-05 at 23:34 +, Gavin Swanson wrote:
> http://stackoverflow.com/a/4470763
>
>
> On Fri, Jun 5, 2015, 7:21 PM Owen Williams
> wr
http://stackoverflow.com/a/4470763
On Fri, Jun 5, 2015, 7:21 PM Owen Williams wrote:
> Since CSAMPLE is a simple type, assignment is best -- and when it works,
> assignment is the way to go (hurray for smart compilers eliding copies).
> With the form sample(0.0), it gives the impression that CSA
Since CSAMPLE is a simple type, assignment is best -- and when it works,
assignment is the way to go (hurray for smart compilers eliding copies).
With the form sample(0.0), it gives the impression that CSAMPLE is a
complex type with a constructor.
On Fri, 2015-06-05 at 22:16 +, Gavin Swanson w
CSAMPLE sample(0.0);
On Fri, Jun 5, 2015, 4:45 PM Owen Williams wrote:
> On Fri, 2015-06-05 at 22:30 +0200, Daniel Schürmann wrote:
>
> > CSAMPLE sample = 0.0;
>
> This one. auto should really only be used when assigning from a
> function whose return value is obvious.
>
>
>
>
>
> -
On Fri, 2015-06-05 at 22:30 +0200, Daniel Schürmann wrote:
> CSAMPLE sample = 0.0;
This one. auto should really only be used when assigning from a
function whose return value is obvious.
--
__
Hi
I have updated
http://mixxx.org/wiki/doku.php/coding_guidelines?auto
according to our discussion.
It is still a draft. Lets tweak it until we have a commitment.
I am unsure what is the recommended version for our own typedefs:
CSAMPLE sample = 0.0;
auto sample = (CSAMPLE)0.0;
auto sample =
On Fri, 2015-06-05 at 08:14 -0400, RJ Ryan wrote:
>
> Which can pretty much be summarized as "use auto to prevent repeating
> yourself".
My rule of thumb is, use auto when the type is long AND easily
understandable from the context. So don't use auto instead of QString
"just because," but do
On Fri, Jun 5, 2015 at 1:35 AM, Sean M. Pappalardo - D.J. Pegasus <
spappala...@mixxx.org> wrote:
>
>
> On 06/04/2015 09:43 PM, RJ Ryan wrote:
>
>> * Visual Studio 2013 (12.0)
>>
>
> Does VS2015 offer more C++11 features? Since it's free, we can just
> declare that to be the minimum version from h
On Fri, Jun 5, 2015 at 4:38 AM, Max Linke wrote:
>
>
> On 06/05/2015 09:55 AM, Daniel Schürmann wrote:
> > Hi all.
> >
> > Good news! Thank you RJ.
> >
> > I just one objection to the C++11 white list.
> >
> > The new keyword "auto".
>
>
> No auto is awesome. I've started a new simulation Monteca
Hi Max,
Thank you for the nice blog.
I did not know all these reason pro "auto".
I am currently working in a huge c# project, which uses a Mixed style "var"
/ explicit types.
Since It is not all my code, It is sometimes a pain to understand the code
with all the vars and the
mixed style:
QLis
On 06/05/2015 09:55 AM, Daniel Schürmann wrote:
> Hi all.
>
> Good news! Thank you RJ.
>
> I just one objection to the C++11 white list.
>
> The new keyword "auto".
No auto is awesome. I've started a new simulation Montecarlo simulation
program for my PhD and use exclusively auto to declare my
Hi all.
Good news! Thank you RJ.
I just one objection to the C++11 white list.
The new keyword "auto".
IMHO "auto" helps to speed up the code writing. But it makes the code
harder to understand. Some IDEs are starting to display the real type, but
that does not help
in GitHub reviews or other ed
And ho. ly. crap. Microsoft, yes, Microsoft, now has a version of their
VS code editor that runs natively on Linux and Mac:
https://www.visualstudio.com/products/code-vs
Not that I'd use it because it will likely push developers to use
Microsoft-specific functionality as VS always has, but I'm
On 06/04/2015 09:43 PM, RJ Ryan wrote:
* Visual Studio 2013 (12.0)
Does VS2015 offer more C++11 features? Since it's free, we can just
declare that to be the minimum version from here on.
Sincerely,
Sean M. Pappalardo
"D.J. Pegasus"
Mixxx Developer - Controller Specialist
smime.p7s
Desc
Mixxx is switching to C++11! The master branch now has -std=c++11 turned
on. 1.12 will be the last release without C++11 support.
This means we have new minimum requirements for compilers:
* Visual Studio 2013 (12.0)
* GCC 4.8 (supported on Ubuntu 14.04 and up)
* Clang 3.3 (supported on Ubuntu 14.
> Qt5 and C++11
Interesting! One more reason for looking forward to the release then. :)
Cheers,
Nico
On Tue, Mar 31, 2015 at 3:32 PM RJ Ryan wrote:
> Hey Nico,
>
> So far we don't use any C++11 features (or a few that happen to be
> supported on all our compilers but slipped through sneakil
Hey Nico,
So far we don't use any C++11 features (or a few that happen to be
supported on all our compilers but slipped through sneakily :) ). After the
next major release, we're going to make two big switches: Qt5 and C++11.
Though I would be in favor of starting small with a whitelist to start (
Currently our Mac build environment does not support c++11, so none of
the features are allowed yet. After this release we will be updating
the builders so we can start using it.
Owen
On Tue, 2015-03-31 at 08:42 +, Nico Schlömer wrote:
> Hi all,
>
>
> I'm not sure if this has been asked be
Hi all,
I'm not sure if this has been asked before, and if yes, please just point
me to the relevant discussion.
Otherwise: Does Mixxx have a policy of what C++11 features are eligible, or
are there any plans for admitting C++11 features to the source code in the
future?
Cheers,
Nico
30 matches
Mail list logo