Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
F
frama-c
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
14
Issues
14
List
Boards
Labels
Service Desk
Milestones
Merge Requests
0
Merge Requests
0
Operations
Operations
Incidents
Packages & Registries
Packages & Registries
Container Registry
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
pub
frama-c
Commits
cc8a6d67
Commit
cc8a6d67
authored
Nov 20, 2020
by
Loïc Correnson
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[ivette] refactor api directory
parent
1468f10e
Changes
19
Hide whitespace changes
Inline
Side-by-side
Showing
19 changed files
with
75 additions
and
67 deletions
+75
-67
ivette/api/generated/kernel/ast/index.ts
ivette/api/generated/kernel/ast/index.ts
+9
-9
ivette/api/generated/kernel/data/index.ts
ivette/api/generated/kernel/data/index.ts
+1
-1
ivette/api/generated/kernel/project/index.ts
ivette/api/generated/kernel/project/index.ts
+1
-1
ivette/api/generated/kernel/properties/index.ts
ivette/api/generated/kernel/properties/index.ts
+9
-9
ivette/api/generated/kernel/services/index.ts
ivette/api/generated/kernel/services/index.ts
+5
-5
ivette/api/generated/plugins/dive/index.ts
ivette/api/generated/plugins/dive/index.ts
+9
-9
ivette/api/generated/plugins/eva/general/index.ts
ivette/api/generated/plugins/eva/general/index.ts
+5
-5
ivette/api/generated/plugins/eva/values/index.ts
ivette/api/generated/plugins/eva/values/index.ts
+5
-5
ivette/api/server_tsc.ml
ivette/api/server_tsc.ml
+16
-7
ivette/src/frama-c/dive/Dive.tsx
ivette/src/frama-c/dive/Dive.tsx
+1
-1
ivette/src/frama-c/states.ts
ivette/src/frama-c/states.ts
+1
-1
ivette/src/frama-c/utils.ts
ivette/src/frama-c/utils.ts
+1
-1
ivette/src/renderer/ASTinfo.tsx
ivette/src/renderer/ASTinfo.tsx
+1
-2
ivette/src/renderer/ASTview.tsx
ivette/src/renderer/ASTview.tsx
+2
-2
ivette/src/renderer/Globals.tsx
ivette/src/renderer/Globals.tsx
+1
-1
ivette/src/renderer/Properties.tsx
ivette/src/renderer/Properties.tsx
+3
-3
ivette/src/renderer/Values.tsx
ivette/src/renderer/Values.tsx
+2
-2
ivette/tsconfig.json
ivette/tsconfig.json
+2
-2
ivette/webpack.renderer.js
ivette/webpack.renderer.js
+1
-1
No files found.
ivette/api/kernel/ast/index.ts
→
ivette/api/
generated/
kernel/ast/index.ts
View file @
cc8a6d67
...
...
@@ -3,7 +3,7 @@
/**
Ast Services
@packageDocumentation
@module api/kernel/ast
@module
frama-c/
api/kernel/ast
*/
//@ts-ignore
...
...
@@ -16,21 +16,21 @@ import * as Server from 'frama-c/server';
import
*
as
State
from
'
frama-c/states
'
;
//@ts-ignore
import
{
byTag
}
from
'
api/kernel/data
'
;
import
{
byTag
}
from
'
frama-c/
api/kernel/data
'
;
//@ts-ignore
import
{
byText
}
from
'
api/kernel/data
'
;
import
{
byText
}
from
'
frama-c/
api/kernel/data
'
;
//@ts-ignore
import
{
jTag
}
from
'
api/kernel/data
'
;
import
{
jTag
}
from
'
frama-c/
api/kernel/data
'
;
//@ts-ignore
import
{
jTagSafe
}
from
'
api/kernel/data
'
;
import
{
jTagSafe
}
from
'
frama-c/
api/kernel/data
'
;
//@ts-ignore
import
{
jText
}
from
'
api/kernel/data
'
;
import
{
jText
}
from
'
frama-c/
api/kernel/data
'
;
//@ts-ignore
import
{
jTextSafe
}
from
'
api/kernel/data
'
;
import
{
jTextSafe
}
from
'
frama-c/
api/kernel/data
'
;
//@ts-ignore
import
{
tag
}
from
'
api/kernel/data
'
;
import
{
tag
}
from
'
frama-c/
api/kernel/data
'
;
//@ts-ignore
import
{
text
}
from
'
api/kernel/data
'
;
import
{
text
}
from
'
frama-c/
api/kernel/data
'
;
const
compute_internal
:
Server
.
ExecRequest
<
null
,
null
>
=
{
kind
:
Server
.
RqKind
.
EXEC
,
...
...
ivette/api/kernel/data/index.ts
→
ivette/api/
generated/
kernel/data/index.ts
View file @
cc8a6d67
...
...
@@ -3,7 +3,7 @@
/**
Informations
@packageDocumentation
@module api/kernel/data
@module
frama-c/
api/kernel/data
*/
//@ts-ignore
...
...
ivette/api/kernel/project/index.ts
→
ivette/api/
generated/
kernel/project/index.ts
View file @
cc8a6d67
...
...
@@ -3,7 +3,7 @@
/**
Project Management
@packageDocumentation
@module api/kernel/project
@module
frama-c/
api/kernel/project
*/
//@ts-ignore
...
...
ivette/api/kernel/properties/index.ts
→
ivette/api/
generated/
kernel/properties/index.ts
View file @
cc8a6d67
...
...
@@ -3,7 +3,7 @@
/**
Property Services
@packageDocumentation
@module api/kernel/properties
@module
frama-c/
api/kernel/properties
*/
//@ts-ignore
...
...
@@ -16,21 +16,21 @@ import * as Server from 'frama-c/server';
import
*
as
State
from
'
frama-c/states
'
;
//@ts-ignore
import
{
byTag
}
from
'
api/kernel/data
'
;
import
{
byTag
}
from
'
frama-c/
api/kernel/data
'
;
//@ts-ignore
import
{
jTag
}
from
'
api/kernel/data
'
;
import
{
jTag
}
from
'
frama-c/
api/kernel/data
'
;
//@ts-ignore
import
{
jTagSafe
}
from
'
api/kernel/data
'
;
import
{
jTagSafe
}
from
'
frama-c/
api/kernel/data
'
;
//@ts-ignore
import
{
tag
}
from
'
api/kernel/data
'
;
import
{
tag
}
from
'
frama-c/
api/kernel/data
'
;
//@ts-ignore
import
{
bySource
}
from
'
api/kernel/services
'
;
import
{
bySource
}
from
'
frama-c/
api/kernel/services
'
;
//@ts-ignore
import
{
jSource
}
from
'
api/kernel/services
'
;
import
{
jSource
}
from
'
frama-c/
api/kernel/services
'
;
//@ts-ignore
import
{
jSourceSafe
}
from
'
api/kernel/services
'
;
import
{
jSourceSafe
}
from
'
frama-c/
api/kernel/services
'
;
//@ts-ignore
import
{
source
}
from
'
api/kernel/services
'
;
import
{
source
}
from
'
frama-c/
api/kernel/services
'
;
/** Property Kinds */
export
enum
propKind
{
...
...
ivette/api/kernel/services/index.ts
→
ivette/api/
generated/
kernel/services/index.ts
View file @
cc8a6d67
...
...
@@ -3,7 +3,7 @@
/**
Kernel Services
@packageDocumentation
@module api/kernel/services
@module
frama-c/
api/kernel/services
*/
//@ts-ignore
...
...
@@ -16,13 +16,13 @@ import * as Server from 'frama-c/server';
import
*
as
State
from
'
frama-c/states
'
;
//@ts-ignore
import
{
byTag
}
from
'
api/kernel/data
'
;
import
{
byTag
}
from
'
frama-c/
api/kernel/data
'
;
//@ts-ignore
import
{
jTag
}
from
'
api/kernel/data
'
;
import
{
jTag
}
from
'
frama-c/
api/kernel/data
'
;
//@ts-ignore
import
{
jTagSafe
}
from
'
api/kernel/data
'
;
import
{
jTagSafe
}
from
'
frama-c/
api/kernel/data
'
;
//@ts-ignore
import
{
tag
}
from
'
api/kernel/data
'
;
import
{
tag
}
from
'
frama-c/
api/kernel/data
'
;
const
getConfig_internal
:
Server
.
GetRequest
<
null
,
...
...
ivette/api/plugins/dive/index.ts
→
ivette/api/
generated/
plugins/dive/index.ts
View file @
cc8a6d67
...
...
@@ -3,7 +3,7 @@
/**
Dive Services
@packageDocumentation
@module api/plugins/dive
@module
frama-c/
api/plugins/dive
*/
//@ts-ignore
...
...
@@ -16,21 +16,21 @@ import * as Server from 'frama-c/server';
import
*
as
State
from
'
frama-c/states
'
;
//@ts-ignore
import
{
byLocation
}
from
'
api/kernel/ast
'
;
import
{
byLocation
}
from
'
frama-c/
api/kernel/ast
'
;
//@ts-ignore
import
{
byMarker
}
from
'
api/kernel/ast
'
;
import
{
byMarker
}
from
'
frama-c/
api/kernel/ast
'
;
//@ts-ignore
import
{
jLocation
}
from
'
api/kernel/ast
'
;
import
{
jLocation
}
from
'
frama-c/
api/kernel/ast
'
;
//@ts-ignore
import
{
jLocationSafe
}
from
'
api/kernel/ast
'
;
import
{
jLocationSafe
}
from
'
frama-c/
api/kernel/ast
'
;
//@ts-ignore
import
{
jMarker
}
from
'
api/kernel/ast
'
;
import
{
jMarker
}
from
'
frama-c/
api/kernel/ast
'
;
//@ts-ignore
import
{
jMarkerSafe
}
from
'
api/kernel/ast
'
;
import
{
jMarkerSafe
}
from
'
frama-c/
api/kernel/ast
'
;
//@ts-ignore
import
{
location
}
from
'
api/kernel/ast
'
;
import
{
location
}
from
'
frama-c/
api/kernel/ast
'
;
//@ts-ignore
import
{
marker
}
from
'
api/kernel/ast
'
;
import
{
marker
}
from
'
frama-c/
api/kernel/ast
'
;
/** Parametrization of the exploration range. */
export
interface
range
{
...
...
ivette/api/plugins/eva/general/index.ts
→
ivette/api/
generated/
plugins/eva/general/index.ts
View file @
cc8a6d67
...
...
@@ -3,7 +3,7 @@
/**
Eva General Services
@packageDocumentation
@module api/plugins/eva/general
@module
frama-c/
api/plugins/eva/general
*/
//@ts-ignore
...
...
@@ -16,13 +16,13 @@ import * as Server from 'frama-c/server';
import
*
as
State
from
'
frama-c/states
'
;
//@ts-ignore
import
{
byMarker
}
from
'
api/kernel/ast
'
;
import
{
byMarker
}
from
'
frama-c/
api/kernel/ast
'
;
//@ts-ignore
import
{
jMarker
}
from
'
api/kernel/ast
'
;
import
{
jMarker
}
from
'
frama-c/
api/kernel/ast
'
;
//@ts-ignore
import
{
jMarkerSafe
}
from
'
api/kernel/ast
'
;
import
{
jMarkerSafe
}
from
'
frama-c/
api/kernel/ast
'
;
//@ts-ignore
import
{
marker
}
from
'
api/kernel/ast
'
;
import
{
marker
}
from
'
frama-c/
api/kernel/ast
'
;
const
getCallers_internal
:
Server
.
GetRequest
<
Json
.
key
<
'
#fct
'
>
,
...
...
ivette/api/plugins/eva/values/index.ts
→
ivette/api/
generated/
plugins/eva/values/index.ts
View file @
cc8a6d67
...
...
@@ -3,7 +3,7 @@
/**
Eva Values
@packageDocumentation
@module api/plugins/eva/values
@module
frama-c/
api/plugins/eva/values
*/
//@ts-ignore
...
...
@@ -16,13 +16,13 @@ import * as Server from 'frama-c/server';
import
*
as
State
from
'
frama-c/states
'
;
//@ts-ignore
import
{
byMarker
}
from
'
api/kernel/ast
'
;
import
{
byMarker
}
from
'
frama-c/
api/kernel/ast
'
;
//@ts-ignore
import
{
jMarker
}
from
'
api/kernel/ast
'
;
import
{
jMarker
}
from
'
frama-c/
api/kernel/ast
'
;
//@ts-ignore
import
{
jMarkerSafe
}
from
'
api/kernel/ast
'
;
import
{
jMarkerSafe
}
from
'
frama-c/
api/kernel/ast
'
;
//@ts-ignore
import
{
marker
}
from
'
api/kernel/ast
'
;
import
{
marker
}
from
'
frama-c/
api/kernel/ast
'
;
/** CallStack */
export
interface
callstack
{
...
...
ivette/api/server_tsc.ml
View file @
cc8a6d67
...
...
@@ -15,12 +15,20 @@ module TSC = Self.Action
let
help
=
"Generate TypeScript API"
end
)
module
API
=
Self
.
String
(
struct
let
option_name
=
"-server-tsc-pkg"
let
arg_name
=
"dir"
let
default
=
"frama-c/api"
let
help
=
Printf
.
sprintf
"Output package (default is '%s')"
default
end
)
module
OUT
=
Self
.
String
(
struct
let
option_name
=
"-server-tsc-out"
let
arg_name
=
"dir"
let
default
=
"api"
let
help
=
"Output directory (default is './api')"
let
default
=
"api
/generated
"
let
help
=
Printf
.
sprintf
"Output directory (default is '%s')"
default
end
)
module
Md
=
Markdown
...
...
@@ -474,12 +482,13 @@ let makeIgnore fmt msg =
let
makePackage
pkg
name
fmt
=
begin
let
open
Pkg
in
let
framac
=
API
.
get
()
in
Format
.
fprintf
fmt
"/* --- Generated Frama-C Server API --- */@
\n
@
\n
"
;
Format
.
fprintf
fmt
"/**@
\n
%s@
\n
"
pkg
.
p_title
;
if
pkg
.
p_descr
<>
[]
then
Format
.
fprintf
fmt
"@
\n
@[<hov 0>%a@]@
\n
@
\n
"
pp_descr
pkg
.
p_descr
;
Format
.
fprintf
fmt
" @@packageDocumentation@
\n
"
;
Format
.
fprintf
fmt
" @@module
api/%s@
\n
"
name
;
Format
.
fprintf
fmt
" @@module
%s/%s@
\n
"
framac
name
;
Format
.
fprintf
fmt
"*/@
\n
@."
;
let
names
=
Pkg
.
resolve
~
keywords
pkg
in
makeIgnore
fmt
"import * as Json from 'dome/data/json';@
\n
"
;
...
...
@@ -494,11 +503,11 @@ let makePackage pkg name fmt =
then
let
pkg
=
Pkg
.
name_of_pkg
~
sep
:
"/"
id
.
plugin
id
.
package
in
if
id
.
name
=
name
then
makeIgnore
fmt
"import { %s } from '
api
/%s';@
\n
"
name
pkg
makeIgnore
fmt
"import { %s } from '
%s
/%s';@
\n
"
name
framac
pkg
else
makeIgnore
fmt
"import { %s: %s } from '
api
/%s';@
\n
"
id
.
name
name
pkg
makeIgnore
fmt
"import { %s: %s } from '
%s
/%s';@
\n
"
id
.
name
name
framac
pkg
)
names
;
List
.
iter
(
makeDeclaration
fmt
names
)
...
...
ivette/src/frama-c/dive/Dive.tsx
View file @
cc8a6d67
...
...
@@ -5,7 +5,7 @@ import * as Dome from 'dome';
import
*
as
Server
from
'
frama-c/server
'
;
import
*
as
States
from
'
frama-c/states
'
;
import
*
as
API
from
'
api/plugins/dive
'
;
import
*
as
API
from
'
frama-c/
api/plugins/dive
'
;
import
Cytoscape
from
'
cytoscape
'
;
import
CytoscapeComponent
from
'
react-cytoscapejs
'
;
...
...
ivette/src/frama-c/states.ts
View file @
cc8a6d67
...
...
@@ -479,7 +479,7 @@ export type HistorySelectActions = 'HISTORY_PREV' | 'HISTORY_NEXT';
/** A selection of multiple locations. */
export
interface
MultipleSelection
{
/** The index of the current selected location in [[
possible
Selections]]. */
/** The index of the current selected location in [[
all
Selections]]. */
index
:
number
;
/** All locations forming a multiple selection. */
allSelections
:
Location
[];
...
...
ivette/src/frama-c/utils.ts
View file @
cc8a6d67
...
...
@@ -9,7 +9,7 @@
import
*
as
Dome
from
'
dome
'
;
import
*
as
DomeBuffers
from
'
dome/text/buffers
'
;
import
*
as
KernelData
from
'
api/kernel/data
'
;
import
*
as
KernelData
from
'
frama-c/
api/kernel/data
'
;
const
D
=
new
Dome
.
Debug
(
'
Utils
'
);
...
...
ivette/src/renderer/ASTinfo.tsx
View file @
cc8a6d67
...
...
@@ -10,8 +10,7 @@ import { Vfill } from 'dome/layout/boxes';
import
{
RichTextBuffer
}
from
'
dome/text/buffers
'
;
import
{
Text
}
from
'
dome/text/editors
'
;
import
{
Component
}
from
'
frama-c/LabViews
'
;
import
{
getInfo
}
from
'
api/kernel/ast
'
;
import
{
getInfo
}
from
'
frama-c/api/kernel/ast
'
;
// --------------------------------------------------------------------------
// --- Information Panel
...
...
ivette/src/renderer/ASTview.tsx
View file @
cc8a6d67
...
...
@@ -15,8 +15,8 @@ import { RichTextBuffer } from 'dome/text/buffers';
import
{
Text
}
from
'
dome/text/editors
'
;
import
{
IconButton
}
from
'
dome/controls/buttons
'
;
import
{
Component
,
TitleBar
}
from
'
frama-c/LabViews
'
;
import
{
printFunction
,
markerInfo
}
from
'
api/kernel/ast
'
;
import
{
getCallers
,
getDeadCode
}
from
'
api/plugins/eva/general
'
;
import
{
printFunction
,
markerInfo
}
from
'
frama-c/
api/kernel/ast
'
;
import
{
getCallers
,
getDeadCode
}
from
'
frama-c/
api/plugins/eva/general
'
;
import
'
codemirror/mode/clike/clike
'
;
import
'
codemirror/theme/ambiance.css
'
;
...
...
ivette/src/renderer/Globals.tsx
View file @
cc8a6d67
...
...
@@ -6,7 +6,7 @@ import React from 'react';
import
{
Section
,
Item
}
from
'
dome/frame/sidebars
'
;
import
*
as
States
from
'
frama-c/states
'
;
import
{
alpha
}
from
'
dome/data/compare
'
;
import
{
functions
,
functionsData
}
from
'
api/kernel/ast
'
;
import
{
functions
,
functionsData
}
from
'
frama-c/
api/kernel/ast
'
;
// --------------------------------------------------------------------------
// --- Globals Section
...
...
ivette/src/renderer/Properties.tsx
View file @
cc8a6d67
...
...
@@ -19,9 +19,9 @@ import { Scroll, Folder } from 'dome/layout/boxes';
import
{
RSplit
}
from
'
dome/layout/splitters
'
;
import
{
source
as
SourceLoc
}
from
'
api/kernel/services
'
;
import
{
statusData
as
Property
}
from
'
api/kernel/properties
'
;
import
*
as
Properties
from
'
api/kernel/properties
'
;
import
{
source
as
SourceLoc
}
from
'
frama-c/
api/kernel/services
'
;
import
{
statusData
as
Property
}
from
'
frama-c/
api/kernel/properties
'
;
import
*
as
Properties
from
'
frama-c/
api/kernel/properties
'
;
// --------------------------------------------------------------------------
// --- Filters
...
...
ivette/src/renderer/Values.tsx
View file @
cc8a6d67
...
...
@@ -5,8 +5,8 @@
import
React
from
'
react
'
;
import
*
as
States
from
'
frama-c/states
'
;
import
*
as
Json
from
'
dome/data/json
'
;
import
*
as
Eva
from
'
api/plugins/eva/values
'
;
import
*
as
Ast
from
'
api/kernel/ast
'
;
import
*
as
Eva
from
'
frama-c/
api/plugins/eva/values
'
;
import
*
as
Ast
from
'
frama-c/
api/kernel/ast
'
;
import
*
as
Compare
from
'
dome/data/compare
'
;
import
{
Table
,
Column
}
from
'
dome/table/views
'
;
...
...
ivette/tsconfig.json
View file @
cc8a6d67
...
...
@@ -43,7 +43,7 @@
"resolveJsonModule"
:
true
,
/*
Allow
to
load
JSON
files
as
module.
*/
"baseUrl"
:
"."
,
/*
Base
directory
to
resolve
non-absolute
module
names.
*/
"paths"
:
{
/*
A
series
of
entries
which
re-map
imports
to
lookup
locations
relative
to
the
'baseUrl'.
*/
"
api/*"
:
[
"api
/*"
],
"
frama-c/api/*"
:
[
"api/generated
/*"
],
"frama-c/*"
:
[
"src/frama-c/*"
],
"dome"
:
[
"src/dome/src/renderer/dome.tsx"
],
"dome/system"
:
[
"src/dome/src/misc/system.js"
],
...
...
@@ -103,7 +103,7 @@
"src/frama-c/server.ts"
,
"src/frama-c/states.ts"
,
"src/frama-c/utils.ts"
,
"api"
,
"api
/generated
"
,
"src/dome/src/renderer"
,
"src/dome/src/misc/utils.ts"
,
"src/dome/src/misc/system.ts"
,
...
...
ivette/webpack.renderer.js
View file @
cc8a6d67
...
...
@@ -27,7 +27,7 @@ module.exports = {
resolve
:
{
extensions
:
[
'
.ts
'
,
'
.tsx
'
,
'
.js
'
,
'
jsx
'
,
'
.json
'
],
alias
:
{
'
api
'
:
path
.
resolve
(
__dirname
,
'
api
'
),
'
frama-c/api
'
:
path
.
resolve
(
__dirname
,
'
api/generated
'
),
'
frama-c
'
:
path
.
resolve
(
__dirname
,
'
src/frama-c
'
),
'
@plugins
'
:
path
.
resolve
(
__dirname
,
'
src/plugins
'
),
'
dome/misc
'
:
path
.
resolve
(
DOME
,
'
src/misc
'
),
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment