enable_if and conversion operator?

后端 未结 4 2032
天命终不由人
天命终不由人 2020-12-30 04:18

Any chance to use enable_if with a type conversion operator? Seems tricky, since both return type and parameters list are implicit.

4条回答
  •  囚心锁ツ
    2020-12-30 05:07

    dixit the documentation:
    There does not seem to be a way to specify an enabler for a conversion operator. Converting constructors, however, can have enablers as extra default arguments.

提交回复
热议问题