Invention Grant
- Patent Title: Systems and methods for converting typed code
-
Application No.: US15083167Application Date: 2016-03-28
-
Publication No.: US10013245B2Publication Date: 2018-07-03
- Inventor: Julien Marcel Verlaguet
- Applicant: Facebook, Inc.
- Applicant Address: US CA Menlo Park
- Assignee: Facebook, Inc.
- Current Assignee: Facebook, Inc.
- Current Assignee Address: US CA Menlo Park
- Agency: Sheppard Mullin Richter & Hampton LLP
- Main IPC: G06F9/45
- IPC: G06F9/45 ; G06F8/51 ; G06F9/38 ; G06F8/41 ; G06F8/40 ; G06F9/455

Abstract:
Techniques provided implement automatic data type annotation in dynamically-typed source code. A codebase, which may comprise a plurality of source code files, is scanned at a global level. The resulting scanned data may describe characteristics of the codebase, including variable and function usage. Based on inferences drawn from the scanning, data types are determined for different variables, expressions, or functions to facilitate conversion from dynamically-typed source code to statically-typed source code. For example, if a function is called once with a parameter value of data type A (e.g., class A), and another time with a parameter value of data type B (e.g., class B), a conversion tool may annotate the parameter variable in the declaration of the function with a data type D (e.g., class d) when data type D is identified as a common ancestor (e.g., superclass) to both data type A and data type B.
Public/Granted literature
- US20160210129A1 SYSTEMS AND METHODS FOR CONVERTING TYPED CODE Public/Granted day:2016-07-21
Information query