Léa Saviot
0a21ed2cfb
[liba] strlcpy third argument in size, not length
2020-02-12 15:13:17 +01:00
Émilie Feral
4025d75734
[apps/code] Fix number of displayable rows in ConsoleController
2020-02-12 15:13:17 +01:00
Émilie Feral
d64321d116
[apps/code] Remove useless class member in ConsoleController
2020-02-12 15:13:17 +01:00
Léa Saviot
e0bbc73b8b
[apps/regression] Fix code cleaning
2020-02-12 15:13:17 +01:00
Ruben Dashyan
51cc6a4d71
[poincare/layout_helper] Simplify Infix and Prefix
2020-02-12 15:13:17 +01:00
Ruben Dashyan
ad938aed48
[poincare/tree_pool] Factor expression in registerNode
2020-02-12 15:13:17 +01:00
Ruben Dashyan
78f1270752
[poincare/tree_pool] Correct identifier type in registerNode
2020-02-12 15:13:17 +01:00
Ruben Dashyan
ff4879abb1
[poincare/tree_pool] Factor updateNodeForIdentifierFromNode
...
Hence fixing typo in assertion
2020-02-12 15:13:17 +01:00
Ruben Dashyan
4313560872
[poincare/tree_pool] Remove redundancy
...
The first condition generally implies the second (if size > 0).
If size == 0 then there is nothing to alloc.
2020-02-12 15:13:16 +01:00
Ruben Dashyan
e984277d66
[poincare/multiplication] shallowBeautify and denominator call new splitIntoNormalForm
2020-02-12 15:13:16 +01:00
Léa Saviot
0209c6d2d4
[ion/storage] Increase size to 32K
2020-02-12 15:13:16 +01:00
Léa Saviot
4ffcace024
[ion/storage] Add TODO about code optimization
2020-02-12 15:13:16 +01:00
Léa Saviot
c1b792c23d
[apps/code] Get out of script edition on usb enumeration
...
The storage needs to be in a clean state
2020-02-12 15:13:16 +01:00
Léa Saviot
7e801906b8
[test/ion] Add Storage available space moving test
2020-02-12 15:13:16 +01:00
Léa Saviot
5853e96947
[apps/code] Remove EditorController::m_areaBuffer
...
This was a very large buffer that took a lot of RAM space (the size of
the storage). Instead of having it, we just move the available space of
the storage at the end of the edited script, and move it back when the
edition finishes.
This is slower but saves a lot of space.
2020-02-12 15:13:16 +01:00
Léa Saviot
a2a0abdcef
[poincare/TreeNode] Fix hasNode
2020-02-12 15:13:16 +01:00
Léa Saviot
ed211f185a
[poincare/tree_pool] Use uint16_t for node identifiers, not int
2020-02-12 15:13:16 +01:00
Léa Saviot
0a1c6a3d1d
[poincare/tree_pool] Store node offsets, not node pointers
...
This saves place because we store uint16_t, not uint32_t
2020-02-12 15:13:16 +01:00
Léa Saviot
6a62f23000
[poincare/tree_pool] Replace test with assertion
2020-02-12 15:13:16 +01:00
Léa Saviot
23dafffcdc
[poincare/tree_pool] TODO comment about not needed cleaning
2020-02-12 15:13:16 +01:00
Léa Saviot
ea3f23cb09
[poincare/tree_pool] Fix and add assertions on TreePool::node(id)
2020-02-12 15:13:16 +01:00
Émilie Feral
37061b9cb5
[python] Fix gc_collect to be sure to get unaligned pointers
2020-02-12 15:13:16 +01:00
Émilie Feral
4b58efbc0a
[python] Fix stack boundary on the device
2020-02-12 15:13:16 +01:00
Émilie Feral
d1e93a2918
[python] Python stack: fix limit
2020-02-12 15:13:16 +01:00
Léa Saviot
d0a65b01c0
py/qstr: Raise exception in qstr_from_strn if str to intern is too long.
2020-02-12 15:13:16 +01:00
Léa Saviot
c9d337d536
py/builtinimport: Raise exception on empty name.
2020-02-12 15:13:16 +01:00
Ruben Dashyan
95c7235831
[poincare] Align implementation of shallowReduce in Symbol and Function
2020-02-12 15:13:16 +01:00
Ruben Dashyan
70c9d063a2
[poincare/symbol] Use replaceWithInPlace in shallowReduce
2020-02-12 15:13:16 +01:00
Ruben Dashyan
686b74cfe4
[poincare/constant] Remove unused parameters from templatedApproximate
2020-02-12 15:13:16 +01:00
Ruben Dashyan
961a0f5f2b
[poincare/constant] Simplify shallowReduce
2020-02-12 15:13:16 +01:00
Ruben Dashyan
c238c5f736
[poincare/symbol_abstract] Remove unnecessary friend class Store
2020-02-12 15:13:16 +01:00
Ruben Dashyan
f0bfb41cab
[poincare/symbol_abstract] Factor serialize
2020-02-12 15:13:16 +01:00
Ruben Dashyan
87c1f4f39c
[poincare] Remove redundancy
...
TreeNode::serialize(char * buffer, int bufferSize, ...) returns
the number of chars it did write in buffer, null-terminating char
excluded.
strlcpy(char * dst, const char * src, size_t len) returns the length of
src.
Hence the min.
The case where bufferSize equals 0 does not need to be handled separately
since it is already contained in the min.
2020-02-12 15:13:16 +01:00
Ruben Dashyan
e4820a52f7
[poincare/symbol_abstract] Make nodeSize private
2020-02-12 15:13:16 +01:00
Ruben Dashyan
4bdc2043c8
[poincare/power] coding style in denominator
2020-02-12 15:13:16 +01:00
Ruben Dashyan
1556e2daad
[poincare/power] Simplify denominator
2020-02-12 15:13:16 +01:00
Ruben Dashyan
55e01fbfd4
[poincare/parser] Remove currentTokenIsReservedFunction and currentTokenIsSpecialIdentifier
...
Use GetReservedFunction and IsSpecialIdentifierName instead.
2020-02-12 15:13:16 +01:00
Ruben Dashyan
9a3e0e9bd3
[poincare/parser] Simplify GetReservedFunction
2020-02-12 15:13:16 +01:00
Ruben Dashyan
4ef46b4fdb
[poincare/parser] IsReservedFunctionName returns a pointer
...
and is hence renamed GetReservedFunction
2020-02-12 15:13:16 +01:00
Ruben Dashyan
967343f75d
[poincare/parser] Remove IsReservedName unused parameter
...
The function is only called in apps/shared/function.
2020-02-12 15:13:16 +01:00
Ruben Dashyan
ab80741838
[poincare/test/simplification] Remove redundant tests
2020-02-12 15:13:16 +01:00
Ruben Dashyan
caa7e6fbbf
[poincare/test/helper] Print richer information when test fails
2020-02-12 15:13:16 +01:00
Ruben Dashyan
3271fc90a4
[poincare/test] Clean header inclusions
2020-02-12 15:13:16 +01:00
Ruben Dashyan
5d1cc521f4
[poincare/expression] Mark nbChildren variable as const in deepBeautify
2020-02-12 15:13:16 +01:00
Ruben Dashyan
6ff28bf5ea
[poincare/addition] Do not recompute the number of children in shallowBeautify
2020-02-12 15:13:16 +01:00
Léa Saviot
4e6378fe18
[test/regression] Add a logistic test
2020-02-12 15:13:16 +01:00
Léa Saviot
a8ead6b66e
[apps/regression] Better initialisation of logistic model coefficients
...
It provides a better fit for:
x = {0.0, 1.0, 2.0, 3.0, 4.0, 5.0, 6.0, 7.0, 8.0, 9.0}
y = {5.0, 9.0, 40.0, 64.0, 144.0, 200.0, 269.0, 278.0, 290.0, 295.0}
(coeffs should be {64.9, 1.0, 297.4})
2020-02-12 15:13:16 +01:00
Léa Saviot
3747b5a4b0
[apps/regression] Virtualize only the specialized part of initCoefs
2020-02-12 15:13:16 +01:00
Léa Saviot
2c497d4f55
Revert "[escher] Force relayouting in a table view"
...
This reverts commit 94281b906d5135f4d3181ca248f572e32be9119c.
The commit created a lot of blinking in the calculation history (for
instance for multiple lines of 56) + "the table's size might be
miscomputed" due to the layouting order (but we have not searched for an
example of such a miscomputation)
2020-02-12 15:13:16 +01:00
Ruben Dashyan
5787d50a45
Revert "[apps/calculation/edit_expression_controller] Define viewWillAppear"
...
This reverts commit 960736203ff2f816688868e3397d178d931fa3c3.
2020-02-12 15:13:16 +01:00