Merge pull request #508 from schungx/master

Fix formatting.
This commit is contained in:
Stephen Chung 2022-01-17 08:19:58 +08:00 committed by GitHub
commit 149197856d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -101,7 +101,7 @@ impl FuncInfo {
match typ {
"" | "()" => "".into(),
RHAI_RESULT_TYPE => RHAI_RESULT_TYPE_EXPAND.into(),
ty if ty.starts_with(RHAI_RESULT_OF_TYPE) && ty.ends_with(">") => {
ty if ty.starts_with(RHAI_RESULT_OF_TYPE) && ty.ends_with('>') => {
RHAI_RESULT_OF_TYPE_EXPAND
.replace("{}", ty[RHAI_RESULT_OF_TYPE.len()..ty.len() - 1].trim())
.into()