Skip to content

leon::Values trait compile issue #1018

Closed Answered by NobodyXu
flisky asked this question in Q&A
Discussion options

You must be logged in to vote

I think this is because of the serde_json_borrow::Index, it requires the key to outlive 'a, this thus somehow make the lifetime of the return value to be relates to the key since you use a subset of key to index the json-value.

Try manually look up the key in Value::object, I think this will solve your problem.

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@flisky
Comment options

Answer selected by flisky
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants