Page 4 of 6

C++ Modules

Posted: June 11th, 2014, 5:04 pm
by Cuchulainn
QuoteOriginally posted by: outrunQuoteOriginally posted by: CuchulainnQuoteRegarding the quotes question: nothing will happen! STL is a*template* library those are always compiled into them. You can't have a dll or lib with templates (but there are new things coming in C++ in that respect).What are these new things? I suspect .NET has them now.Hmf, I can't find it anymore! Is was is some mail about a C++17 feature on modules involving templates.No hurry C++ 17 == 2021?

C++ Modules

Posted: April 3rd, 2016, 7:00 pm
by Cuchulainn
C++17 modules?????? QuoteModules would save me tens of minutes everyday and hours every week! They would remove most inconsistencies we have to deal with constantly, cut significantly compile times and most important of all remove that "are you seriously using this crap" look from non-C++ people's face when you explain them the massive hack that is the PIMPL Idiom. I can't believe the C++ committee is taking up to 2020 to add something so needed to the language, other entities can create, push and phase out 3 languages in the same time, the US can change 2 presidents, a kid can be conceived, born and start primary school!

C++ Modules

Posted: April 4th, 2016, 7:55 pm
by katastrofa
@ "Modules would [...] most important of all remove that "are you seriously using this crap" look from non-C++ people's face when you explain them the massive hack that is the PIMPL Idiom."How?

C++ Modules

Posted: April 5th, 2016, 6:50 am
by Cuchulainn
QuoteOriginally posted by: katastrofa@ "Modules would [...] most important of all remove that "are you seriously using this crap" look from non-C++ people's face when you explain them the massive hack that is the PIMPL Idiom."How?Absolutely.C# uses assemblies/dlls, interfaces and namespaces which is essentially modules that you can load into the application. So neat. I suppose Java is similar. Anecdotal evidence suggests C# developer productivity can be [3,4] times that of C++.DLL does not work with C++, only C. However, assemblies are possible in C++/CLI.pimp (aka Cheshire Cat) was invented by the late John Carolan in ~ 1988. It was needed at the time because of long compilation times on 286 pcs.Lack of modules is a major road block IMO. Consequences1. Top down decomposition into loosely couples subsystems difficult. Engineers work with block diagrams and less with Grammar, as @farmer has described.2. Cannot see the architecture until system has been coded.3. Maintenance costs.

C++ Modules

Posted: April 5th, 2016, 8:42 am
by katastrofa
QuoteOriginally posted by: CuchulainnQuoteOriginally posted by: katastrofa@ "Modules would [...] most important of all remove that "are you seriously using this crap" look from non-C++ people's face when you explain them the massive hack that is the PIMPL Idiom."How?Absolutely.C# uses assemblies/dlls, interfaces and namespaces which is essentially modules that you can load into the application. So neat. I suppose Java is similar. Anecdotal evidence suggests C# developer productivity can be [3,4] times that of C++.DLL does not work with C++, only C. However, assemblies are possible in C++/CLI.pimp (aka Cheshire Cat) was invented by the late John Carolan in ~ 1988. It was needed at the time because of long compilation times on 286 pcs.Lack of modules is a major road block IMO. Consequences1. Top down decomposition into loosely couples subsystems difficult. Engineers work with block diagrams and less with Grammar, as @farmer has described.2. Cannot see the architecture until system has been coded.3. Maintenance costs.I am aware of modules' functionalities. I only don't see how they could replace PIMPL (which I find quite useful and don't see any problems with it, I'm not a programmer though; farmer's thread below? -- please...).

C++ Modules

Posted: April 5th, 2016, 8:52 am
by Cuchulainn
QuoteOriginally posted by: katastrofaQuoteOriginally posted by: CuchulainnQuoteOriginally posted by: katastrofa@ "Modules would [...] most important of all remove that "are you seriously using this crap" look from non-C++ people's face when you explain them the massive hack that is the PIMPL Idiom."How?Absolutely.C# uses assemblies/dlls, interfaces and namespaces which is essentially modules that you can load into the application. So neat. I suppose Java is similar. Anecdotal evidence suggests C# developer productivity can be [3,4] times that of C++.DLL does not work with C++, only C. However, assemblies are possible in C++/CLI.pimp (aka Cheshire Cat) was invented by the late John Carolan in ~ 1988. It was needed at the time because of long compilation times on 286 pcs.Lack of modules is a major road block IMO. Consequences1. Top down decomposition into loosely couples subsystems difficult. Engineers work with block diagrams and less with Grammar, as @farmer has described.2. Cannot see the architecture until system has been coded.3. Maintenance costs.I am aware of modules' functionalities. I only don't see how they could replace PIMPL (which I find quite useful and don't see any problems with it, I'm not a programmer though; farmer's thread below? -- please...).What is a module in your definition? pimpl is useful and a fix. It's 80's technology. And these days we have smart pointers (see Meyers' item #22).

C++ Modules

Posted: April 5th, 2016, 9:01 am
by Cuchulainn
QuoteIn software design, modularity refers to a logical partitioning of the "software design" that allows complex software to be manageable for the purpose of implementation and maintenance. The logic of partitioning may be based on related functions, implementation considerations, data links, or other criteria.So, how do you break the software system into modules? C# easy, C++ difficult. Don't see how pimpl idiom will help except by pure luck. Maybe I'm missing the point. The analogy is building a house by a team of electricians.

C++ Modules

Posted: April 19th, 2016, 8:22 pm
by katastrofa
QuoteOriginally posted by: CuchulainnQuoteOriginally posted by: katastrofaQuoteOriginally posted by: CuchulainnQuoteOriginally posted by: katastrofa@ "Modules would [...] most important of all remove that "are you seriously using this crap" look from non-C++ people's face when you explain them the massive hack that is the PIMPL Idiom."How?Absolutely.C# uses assemblies/dlls, interfaces and namespaces which is essentially modules that you can load into the application. So neat. I suppose Java is similar. Anecdotal evidence suggests C# developer productivity can be [3,4] times that of C++.DLL does not work with C++, only C. However, assemblies are possible in C++/CLI.pimp (aka Cheshire Cat) was invented by the late John Carolan in ~ 1988. It was needed at the time because of long compilation times on 286 pcs.Lack of modules is a major road block IMO. Consequences1. Top down decomposition into loosely couples subsystems difficult. Engineers work with block diagrams and less with Grammar, as @farmer has described.2. Cannot see the architecture until system has been coded.3. Maintenance costs.I am aware of modules' functionalities. I only don't see how they could replace PIMPL (which I find quite useful and don't see any problems with it, I'm not a programmer though; farmer's thread below? -- please...).What is a module in your definition? pimpl is useful and a fix. It's 80's technology. And these days we have smart pointers (see Meyers' item #22).I use PIMPL as an extra layer of abstraction, which allows more freedom in changing the code structure, without subsequent need to recompile the unchanged code that uses it. I've never thought of it as a fix or a hack, otherwise I wouldn't use it. OK, you can say that modules enable doing the same at the binary level, but from the code design viewpoint they are something else. I used to use modules in Fortran or once for callbacks in JavaScript...

C++ Modules

Posted: April 20th, 2016, 6:50 am
by Cuchulainn
QuoteOriginally posted by: katastrofaQuoteOriginally posted by: CuchulainnQuoteOriginally posted by: katastrofaQuoteOriginally posted by: CuchulainnQuoteOriginally posted by: katastrofa@ "Modules would [...] most important of all remove that "are you seriously using this crap" look from non-C++ people's face when you explain them the massive hack that is the PIMPL Idiom."How?Absolutely.C# uses assemblies/dlls, interfaces and namespaces which is essentially modules that you can load into the application. So neat. I suppose Java is similar. Anecdotal evidence suggests C# developer productivity can be [3,4] times that of C++.DLL does not work with C++, only C. However, assemblies are possible in C++/CLI.pimp (aka Cheshire Cat) was invented by the late John Carolan in ~ 1988. It was needed at the time because of long compilation times on 286 pcs.Lack of modules is a major road block IMO. Consequences1. Top down decomposition into loosely couples subsystems difficult. Engineers work with block diagrams and less with Grammar, as @farmer has described.2. Cannot see the architecture until system has been coded.3. Maintenance costs.I am aware of modules' functionalities. I only don't see how they could replace PIMPL (which I find quite useful and don't see any problems with it, I'm not a programmer though; farmer's thread below? -- please...).What is a module in your definition? pimpl is useful and a fix. It's 80's technology. And these days we have smart pointers (see Meyers' item #22).I use PIMPL as an extra layer of abstraction, which allows more freedom in changing the code structure, without subsequent need to recompile the unchanged code that uses it. I've never thought of it as a fix or a hack, otherwise I wouldn't use it. OK, you can say that modules enable doing the same at the binary level, but from the code design viewpoint they are something else. I used to use modules in Fortran or once for callbacks in JavaScript...You can use something, you probably don't know any better :) pimpl is a fix, but never mind. It is a code-level trick and does not scale.C# has assemblies which is a good benchmark for module. An assembly is self-reflective.Fortran modules are something else. AFAIR I think they are close to assemblies.

C++ Modules

Posted: April 20th, 2016, 7:04 am
by Cuchulainn
a dll is a module? Of course, someone should define what a module is;)

C++ Modules

Posted: May 16th, 2016, 10:17 am
by Cuchulainn
DLL in C++ This library was designed to simplify plugin development using C++ in a portable cross-platform manner.

C++ Modules

Posted: May 17th, 2016, 6:52 pm
by katastrofa
It's for dynamic DLL, I presume? Otherwise, what's to simplify...

C++ Modules

Posted: May 17th, 2016, 8:08 pm
by Cuchulainn
QuoteOriginally posted by: katastrofaIt's for dynamic DLL, I presume? Otherwise, what's to simplify...It looks like you can load _classes_ and interfaces in contrast to flat C Windows dlls.looks like .NET assemblies I plan to investigate. If it works then it will be cool for large scale software components.Can we make a DLL in Linux gnu and import it to Visual Studio 2015?

C++ Modules

Posted: May 18th, 2016, 9:40 pm
by katastrofa
I haven't tried, but it looks possible: http://www.blogcompiler.com/2010/07/11/ ... -linux/E.g. NLopt is a standalone library compiled with MinGW for Windows AFAIK.