[odb-users] Templated view class

Boris Kolpackov boris at codesynthesis.com
Fri Jul 3 14:07:29 EDT 2015


Hi Dieter,

dieter.govaerts at bricsys.com <dieter.govaerts at bricsys.com> writes:

> If I rewrite the view class in a templated form, that is equivalent
> in my opinion, as:
> 
> template<class T>
> struct ObjectNameView
> {
>     String name;
> };
> 
> typedef ObjectNameView<Composition> CompositionNameView;
> #pragma db view(CompositionNameView) object(Composition)
> 
> then the odb compiler succeeds but the (visual) c++ compiler fails:

Yes, this is not supported in ODB 2.4.0 but will be in the upcoming
release. If you would like, I can build you pre-release packages. Just
let me know which platform you need the ODB compiler binary for, if
any.

Boris



More information about the odb-users mailing list