~ubuntu-branches/ubuntu/trusty/c++-annotations/trusty

« back to all changes in this revision

Viewing changes to yo/classtemplates/variadicnontype.yo

  • Committer: Package Import Robot
  • Author(s): tony mancill, Frank B. Brokken, tony mancill
  • Date: 2012-02-28 00:50:21 UTC
  • mfrom: (1.1.19)
  • Revision ID: package-import@ubuntu.com-20120228005021-sz7nnodntkvgh7qf
Tags: 9.2.1-1
[ Frank B. Brokken ]
* New upstream release (using flexc++, reauthored polymorphic semantic
  values and unrestricted unions). Upstream release 9.2.0 is implied by
  this release.

[ tony mancill ]
* Set Standards-Version to 3.9.3.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
Variadic templates not necesssarily define template types. Non-types can also
2
 
be used with 
3
 
    hi(variadic non-type parameters) 
 
2
be used with
 
3
    hi(variadic non-type parameters)
4
4
        variadic templates. The following function template accepts any series
5
5
of tt(int) values, forwarding these values to a class template. The class
6
6
template defines an tt(enum) value tt(result) which is returned by the
23
23
        )
24
24
    The tt(sizeof) operator can be used for variadic non-type parameters as
25
25
well: tt(sizeof...(Ints)) would return 3 when used in the first function
26
 
template for tt(forwarder<1, 2, 3>()). 
 
26
template for tt(forwarder<1, 2, 3>()).
27
27
 
28
28
    Variadic non-type parameters are used to define variadic literal
29
29
operators, introduced in section ref(UDL).
30
 
 
31