1

I need to create Tuple. I do:

auto historyTuple = Tuple!(string, "gps", string, "sensor");

I want to initialize with data it's later.

I am getting error:

Error: type Tuple!(string, "gps", string, "sensor") has no value

1 Answer 1

2

The value you specified on the right is actually the type of the tuple. You should instead write

Tuple!(string, "gps", string, "sensor") historyTuple;

However, if you intend to use this tuple very often, you may instead wish to create an alias for it:

alias History = Tuple!(string, "gps", string, "sensor");
History historyTuple;
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.