49
50
if (typeof obj === 'object') {
52
>
switch ((<MarshalledObject>obj).$mid) {
53
>
// eslint-disable-next-line local/code-no-any-casts
54
>
case MarshalledId.Uri: return <any>URI.revive(obj);
55
>
// eslint-disable-next-line local/code-no-any-casts
56
>
case MarshalledId.Regexp: return <any>new RegExp(obj.source, obj.flags);
57
>
// eslint-disable-next-line local/code-no-any-casts
58
>
case MarshalledId.Date: return <any>new Date(obj.source);
59
>
}
60
61
if (
62
obj instanceof VSBuffer
63
|| obj instanceof Uint8Array
65
// eslint-disable-next-line local/code-no-any-casts
66
return <any>obj;