Commit Graph
171 Commits
Author SHA1 Message Date
Mike Auty 4b29cf1986 Objects: Fix incorrect pointer readability check 2020-06-28 19:32:37 +01:00
Mike Auty 16a8e3771b Objects: Make bool an int
We can't inherit from bool, so __new__ can't return a bool, so
everything has be done with int.  However __bool__ is already
defined for int, so it should have no significant impact
(other than type() calls).

Fixes issue 232.
2020-06-18 16:53:14 +01:00
Mike Auty 0c43beb42d Core: Apply yapf across all files again. 2020-05-05 22:14:33 +01:00
Mike Auty 572313cc34 Objects: Make sure bytes provide a template size. 2020-01-16 11:06:16 +00:00
Mike Auty cedca0bb84 Objects: Document void size a little more. 2020-01-15 21:55:30 +00:00
Mike Auty b4a9937da7 Objects: Void has no size, and BitFields don't inherit from Integer. 2020-01-13 02:16:35 +00:00
Mike Auty 0f49673aa0 Objects: Ensure string template objects return the right size. 2020-01-13 01:41:57 +00:00
Mike Auty 3977a3c356 objects: Fixes for the comments in #159 2020-01-10 12:47:06 +00:00
Mike Auty d969d89da9 Objects: Ensure array sizes change with their count 2020-01-10 12:47:06 +00:00
Mike Auty fba6511486 Objects: Add size to ObjectInfo so it can be statically access later 2020-01-10 12:47:06 +00:00
Mike Auty b99ace86fb Tidy up exceptions to be more accurate. 2019-11-13 19:58:14 +00:00
Mike Auty 40fcdf9469 exceptions: SymbolErrors now contain specific information 2019-11-13 19:27:00 +00:00
Mike Auty 648cded5e1 Objects: Fix incorrect Bitfield maths
Turns out that #133 exposed a mistake in how we were using the end_bit
field (and it should have been picked up in review, my bad).
Essentially we were masking based on the length of the end_bit after
*already* shifting by the start_bit.  We should mask then shift, not the
other way around.

May well fix issue #135 (pdb generation will have been affected by
this).
2019-11-13 16:48:14 +00:00
Mike Auty face38436e layers: Fix up uses of is_valid. 2019-11-12 09:09:51 +00:00
Mike Auty 9a17beb77f Ensure consistency of importing interfaces. 2019-10-02 01:18:46 +01:00
Mike Auty e0b9d72c84 Update the license URL and LICENSE.txt 2019-09-25 21:44:05 +01:00
Mike Auty d2b892cf94 Fix up docstring errors in documentation build 2019-09-19 23:00:37 +01:00
Mike Auty e922cef316 Improve docstrings for all plugins, and reformat all docstrings. 2019-09-07 22:59:54 +01:00
Mike Auty a3caf39097 Use a mapping to determine kind to class. 2019-08-31 12:57:53 +01:00
Mike Auty 9cde94bceb Change the license blurb on all files. 2019-08-27 23:11:00 +01:00
Mike Auty 4cde0da8a9 Support passing through functions from specific to generic template. 2019-08-10 00:25:21 +01:00
Mike Auty 272224a1b0 Refactor all references to Context.memory to Context.layers. 2019-07-07 17:42:51 +01:00
Mike Auty 94703d88d8 Fix up enumeration object creation. 2019-06-30 23:05:15 +01:00
Mike Auty e503c3667f Improve enumeration support. 2019-06-30 14:12:43 +01:00
Mike Auty 1c0cd7ddaf Make sure objects.utility is imported automatically. 2019-05-09 00:07:59 +01:00
Mike Auty 5b0f99229c Remove the VolTemplateProxy method proxying to fix the slowdown. 2019-04-18 01:48:56 +01:00
Mike Auty 8c76a25b2d Allow VolTemplateProxies to include additional useful methods. 2019-04-17 23:53:36 +01:00
Mike Auty e5d6cd3d16 Add in Enum ObjectTemplate lookup method. 2019-04-17 23:53:22 +01:00
Mike Auty 9b488f89fd Make the default python-type for Chars an int rather than a bytes. 2019-02-06 21:06:12 +00:00
Mike Auty c64ed6a8dd Remove validity checking in favour of static-type checking.
This removes the assertions that checked plugin devs didn't do anything
overly bad in favour of using mypy to ensure appropriate type-checking.

It also moves the ProgressCallback typing information to constants in
order to avoid circular imports (since constants doesn't import
anything).
2019-01-20 02:35:49 +00:00
Mike Auty b13fcb186c Improve typing issues. 2019-01-03 01:13:53 +00:00
Mike Auty 6bb927ebfa Fix up terminology to ensure we only refer to layers not spaces. 2019-01-03 00:40:13 +00:00
Mike Auty fdc6efc4ad Add in the LICENSE and the README. 2018-12-19 23:55:03 +00:00
Andrew Caseandikelos 8f213a95d7 vol_class -> CPPObject 2018-12-19 00:54:51 +00:00
Mike Auty c5ebf91915 Yapf reformat of the patches. 2018-12-19 00:54:51 +00:00
Andrew Caseandikelos 6aac0571e6 add support for objective C classes in OSX and json format 2018-12-19 00:54:51 +00:00
Mike Auty e65a00894a Minor style tweaks and mass changes across the codebase because of it. 2018-12-17 12:46:14 +00:00
Mike Auty b61ac3bd47 Many more typing fixes. 2018-12-17 01:17:06 +00:00
Mike Auty 19572b6e1e Reformat all python files using yapf with custom volatility style. 2018-12-16 16:50:17 +00:00
Mike Auty 9824538bd9 Numerous pycharm warnings resolved
This includes:

* Better ways of checking empty lists
* Not shadowing builtin functions like filter
* Preventing invalid slash warnings by marking strings as regexps
* Removing unnecessary brackets
* Lowercase variable names
* Adding/updating parameters in docstrings
* Removing unused code (lines not chunks)
* Change in not a member tests
* Changing some methods to static
* Shorting range membership checks
* Missing parameters
* Make some exception handlers more specific
* Don't define a lambda to a variable
* A few more instance checks to help type checkers
2018-12-16 13:21:06 +00:00
Mike Auty 29d41470a4 Mass reformat of typing imports
Relented on the strict import of direct objects/classes for the typing
module only.  Typing module components can be directly imported because
it makes the code really painful to read and write otherwise.

This is still in-line with the python style guide adopted from Google at
http://google.github.io/styleguide/pyguide.html section 2.2.
2018-12-16 13:04:22 +00:00
Mike Auty f41e3e0453 Completely rework the primitive data format system. 2018-12-13 18:33:42 +00:00
Mike Auty 9949809198 Fix a minor typo. 2018-12-13 18:33:42 +00:00
Mike Auty b533d19f83 Refactor the data extraction for primitive types. 2018-12-13 18:33:42 +00:00
Mike Auty a78452e361 Fix up ugly int128 hack with a slightly nicer hack. 2018-12-13 15:56:24 +00:00
Mike Auty 8acbe8bba3 Refactor conversion code from objects.utility to a conversion module in renderers. 2018-12-12 23:39:10 +00:00
Mike Auty cf95f6e73e Minor typing fix. 2018-12-08 18:41:13 +00:00
Andrew Caseandikelos 3ab654847e Change NotApplicableValue -> UnparsableValue 2018-12-08 17:34:48 +00:00
Andrew Caseandikelos c6e9763e5a Linux - add bash plugin 2018-12-08 17:34:48 +00:00
Mike Auty 90c964905a Fix up a circular import issue. 2018-11-08 00:25:26 +00:00