Update subscription.rs

This commit is contained in:
sunli 2020-05-13 09:03:19 +08:00
parent b15459f20f
commit 07a5ee4a9f

View File

@ -246,7 +246,7 @@ pub fn generate(object_args: &args::Object, item_impl: &mut ItemImpl) -> Result<
// I think the code here is safe because the lifetime of selection_set is always less than the environment.
let field_selection_set = unsafe {
(&ctx.selection_set
as *const Positioned<#crate_name::parser::ast::SelectionSet>)
as *const #crate_name::Positioned<#crate_name::parser::ast::SelectionSet>)
.as_ref()
.unwrap()
};