Skip to content
This repository has been archived by the owner on Nov 9, 2017. It is now read-only.

Utilities for manipulating untyped JavaScript objects in ActionScript.

License

Notifications You must be signed in to change notification settings

BowlerHatLLC/nextgenas-unsafe

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 

Repository files navigation

NextGenAS Unsafe

Note: This project is no longer under active development. Use at your own risk.

Utilities for manipulating untyped JavaScript objects in ActionScript. The ActionScript Virtual Machine always verifies types at runtime, but when ActionScript is transpiled to JavaScript, there are ways to break out of the compile-time type system at run-time.

Unsafe.cast()

An alternative to normal ActionScript casting that completely bypasses type coercion. In other words, the result may be assigned to any type without generating a compile-time error. Useful for converting untyped JavaScript objects into typed ActionScript objects.

Usage

var point:Object = { x: 2, y: 10 };
var result:IPoint = Unsafe.cast( point );

Special thanks to the following sponsors for their generous support:

About

Utilities for manipulating untyped JavaScript objects in ActionScript.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published