[MAT-387] sed replace all pOG{Numeric,Terminal,Expr}

Use ::Ptr types

[MAT-387] Run sed command correctly this time, fix up compilation errors

[MAT-387] Get rid of remaining pOG...
[MAT-387][WIP] Make terminal constructors private and provide factories
[MAT-387] Terminal factories - compiles but tests fail
[MAT-387] Fix RTTI by using constructors of subclasses
[MAT-387] Correct type of logical matrix by using correct constructor
[MAT-387] Reset shared_ptrs in jterminals test

This is so that they can be deleted whilst the JVM and environment
is still around for their unbinding.
[MAT-387] Make Expr constructors private
[MAT-387] Delete dead code
[MAT-387-API] Delete more dead code
[MAT-387] Separate symbol visibilty and stack flags
[MAT-387] Remove stack flags
[MAT-387] Remove terminal methods that took a raw pointer
Revert "[MAT-387] Remove stack flags"

This reverts commit 624f32238db3e14aaa2cad1d6f1261652b44c9d7.
Revert "[MAT-387] Separate symbol visibilty and stack flags"

This reverts commit a18badaeae084918fa02e7aa300504ac1f183c18.
[MAT-387] Document windows flags
[MAT-387] Remove iss functions that take pointers
[MAT-387] Comment on terminal container
[MAT-387] Add some comments, delete some dead code
[MAT-387] Make some things const refs
[MAT-387] More const