mirror of https://github.com/KLayout/klayout.git
Replaced std::auto_ptr by std::unique_ptr because the latter is deprecated
This commit is contained in:
parent
a1ace443f7
commit
d1e6845ae4
|
|
@ -308,7 +308,7 @@ BD_PUBLIC int strmxor (int argc, char *argv[])
|
|||
l2l_map.insert (std::make_pair (*(*l).second, std::make_pair (-1, -1))).first->second.second = (*l).first;
|
||||
}
|
||||
|
||||
std::auto_ptr<db::Layout> output_layout;
|
||||
std::unique_ptr<db::Layout> output_layout;
|
||||
db::cell_index_type output_top = 0;
|
||||
|
||||
if (! output.empty ()) {
|
||||
|
|
|
|||
|
|
@ -81,7 +81,7 @@ AsIfFlatEdgePairs::in (const EdgePairs &other, bool invert) const
|
|||
op.insert (*o);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatEdgePairs> new_edge_pairs (new FlatEdgePairs ());
|
||||
std::unique_ptr<FlatEdgePairs> new_edge_pairs (new FlatEdgePairs ());
|
||||
|
||||
for (EdgePairsIterator o (begin ()); ! o.at_end (); ++o) {
|
||||
if ((op.find (*o) == op.end ()) == invert) {
|
||||
|
|
@ -140,7 +140,7 @@ void AsIfFlatEdgePairs::invalidate_bbox ()
|
|||
RegionDelegate *
|
||||
AsIfFlatEdgePairs::processed_to_polygons (const EdgePairToPolygonProcessorBase &filter) const
|
||||
{
|
||||
std::auto_ptr<FlatRegion> region (new FlatRegion ());
|
||||
std::unique_ptr<FlatRegion> region (new FlatRegion ());
|
||||
|
||||
if (filter.result_must_not_be_merged ()) {
|
||||
region->set_merged_semantics (false);
|
||||
|
|
@ -162,7 +162,7 @@ AsIfFlatEdgePairs::processed_to_polygons (const EdgePairToPolygonProcessorBase &
|
|||
EdgesDelegate *
|
||||
AsIfFlatEdgePairs::processed_to_edges (const EdgePairToEdgeProcessorBase &filter) const
|
||||
{
|
||||
std::auto_ptr<FlatEdges> edges (new FlatEdges ());
|
||||
std::unique_ptr<FlatEdges> edges (new FlatEdges ());
|
||||
|
||||
if (filter.result_must_not_be_merged ()) {
|
||||
edges->set_merged_semantics (false);
|
||||
|
|
@ -184,7 +184,7 @@ AsIfFlatEdgePairs::processed_to_edges (const EdgePairToEdgeProcessorBase &filter
|
|||
EdgePairsDelegate *
|
||||
AsIfFlatEdgePairs::filtered (const EdgePairFilterBase &filter) const
|
||||
{
|
||||
std::auto_ptr<FlatEdgePairs> new_edge_pairs (new FlatEdgePairs ());
|
||||
std::unique_ptr<FlatEdgePairs> new_edge_pairs (new FlatEdgePairs ());
|
||||
|
||||
for (EdgePairsIterator p (begin ()); ! p.at_end (); ++p) {
|
||||
if (filter.selected (*p)) {
|
||||
|
|
@ -198,7 +198,7 @@ AsIfFlatEdgePairs::filtered (const EdgePairFilterBase &filter) const
|
|||
RegionDelegate *
|
||||
AsIfFlatEdgePairs::polygons (db::Coord e) const
|
||||
{
|
||||
std::auto_ptr<FlatRegion> output (new FlatRegion ());
|
||||
std::unique_ptr<FlatRegion> output (new FlatRegion ());
|
||||
|
||||
for (EdgePairsIterator ep (begin ()); ! ep.at_end (); ++ep) {
|
||||
db::Polygon poly = ep->normalized ().to_polygon (e);
|
||||
|
|
@ -213,7 +213,7 @@ AsIfFlatEdgePairs::polygons (db::Coord e) const
|
|||
EdgesDelegate *
|
||||
AsIfFlatEdgePairs::edges () const
|
||||
{
|
||||
std::auto_ptr<FlatEdges> output (new FlatEdges ());
|
||||
std::unique_ptr<FlatEdges> output (new FlatEdges ());
|
||||
|
||||
for (EdgePairsIterator ep (begin ()); ! ep.at_end (); ++ep) {
|
||||
output->insert (ep->first ());
|
||||
|
|
@ -226,7 +226,7 @@ AsIfFlatEdgePairs::edges () const
|
|||
EdgesDelegate *
|
||||
AsIfFlatEdgePairs::first_edges () const
|
||||
{
|
||||
std::auto_ptr<FlatEdges> output (new FlatEdges ());
|
||||
std::unique_ptr<FlatEdges> output (new FlatEdges ());
|
||||
|
||||
for (EdgePairsIterator ep (begin ()); ! ep.at_end (); ++ep) {
|
||||
output->insert (ep->first ());
|
||||
|
|
@ -238,7 +238,7 @@ AsIfFlatEdgePairs::first_edges () const
|
|||
EdgesDelegate *
|
||||
AsIfFlatEdgePairs::second_edges () const
|
||||
{
|
||||
std::auto_ptr<FlatEdges> output (new FlatEdges ());
|
||||
std::unique_ptr<FlatEdges> output (new FlatEdges ());
|
||||
|
||||
for (EdgePairsIterator ep (begin ()); ! ep.at_end (); ++ep) {
|
||||
output->insert (ep->second ());
|
||||
|
|
@ -253,7 +253,7 @@ AsIfFlatEdgePairs::add (const EdgePairs &other) const
|
|||
FlatEdgePairs *other_flat = dynamic_cast<FlatEdgePairs *> (other.delegate ());
|
||||
if (other_flat) {
|
||||
|
||||
std::auto_ptr<FlatEdgePairs> new_edge_pairs (new FlatEdgePairs (*other_flat));
|
||||
std::unique_ptr<FlatEdgePairs> new_edge_pairs (new FlatEdgePairs (*other_flat));
|
||||
new_edge_pairs->invalidate_cache ();
|
||||
|
||||
size_t n = new_edge_pairs->raw_edge_pairs ().size () + count ();
|
||||
|
|
@ -268,7 +268,7 @@ AsIfFlatEdgePairs::add (const EdgePairs &other) const
|
|||
|
||||
} else {
|
||||
|
||||
std::auto_ptr<FlatEdgePairs> new_edge_pairs (new FlatEdgePairs ());
|
||||
std::unique_ptr<FlatEdgePairs> new_edge_pairs (new FlatEdgePairs ());
|
||||
|
||||
size_t n = count () + other.count ();
|
||||
|
||||
|
|
|
|||
|
|
@ -116,7 +116,7 @@ AsIfFlatEdges::selected_interacting_generic (const Region &other, bool inverse)
|
|||
scanner.insert2 (p.operator-> (), 1);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatEdges> output (new FlatEdges (true));
|
||||
std::unique_ptr<FlatEdges> output (new FlatEdges (true));
|
||||
|
||||
if (! inverse) {
|
||||
|
||||
|
|
@ -157,7 +157,7 @@ AsIfFlatEdges::selected_interacting_generic (const Edges &edges, bool inverse) c
|
|||
scanner.insert (ee.operator-> (), 1);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatEdges> output (new FlatEdges (true));
|
||||
std::unique_ptr<FlatEdges> output (new FlatEdges (true));
|
||||
|
||||
if (! inverse) {
|
||||
|
||||
|
|
@ -198,7 +198,7 @@ AsIfFlatEdges::pull_generic (const Edges &edges) const
|
|||
scanner.insert (ee.operator-> (), 0);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatEdges> output (new FlatEdges (true));
|
||||
std::unique_ptr<FlatEdges> output (new FlatEdges (true));
|
||||
edge_interaction_filter<FlatEdges> filter (*output);
|
||||
scanner.process (filter, 1, db::box_convert<db::Edge> ());
|
||||
|
||||
|
|
@ -227,7 +227,7 @@ AsIfFlatEdges::pull_generic (const Region &other) const
|
|||
scanner.insert2 (p.operator-> (), 1);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatRegion> output (new FlatRegion (true));
|
||||
std::unique_ptr<FlatRegion> output (new FlatRegion (true));
|
||||
|
||||
edge_to_region_interaction_filter<FlatRegion> filter (*output);
|
||||
scanner.process (filter, 1, db::box_convert<db::Edge> (), db::box_convert<db::Polygon> ());
|
||||
|
|
@ -300,7 +300,7 @@ AsIfFlatEdges::extended (coord_type ext_b, coord_type ext_e, coord_type ext_o, c
|
|||
{
|
||||
if (join) {
|
||||
|
||||
std::auto_ptr<FlatRegion> output (new FlatRegion ());
|
||||
std::unique_ptr<FlatRegion> output (new FlatRegion ());
|
||||
db::ShapeGenerator sg (output->raw_polygons (), false);
|
||||
JoinEdgesClusterCollector cluster_collector (&sg, ext_b, ext_e, ext_o, ext_i);
|
||||
|
||||
|
|
@ -321,7 +321,7 @@ AsIfFlatEdges::extended (coord_type ext_b, coord_type ext_e, coord_type ext_o, c
|
|||
|
||||
} else {
|
||||
|
||||
std::auto_ptr<FlatRegion> output (new FlatRegion ());
|
||||
std::unique_ptr<FlatRegion> output (new FlatRegion ());
|
||||
for (EdgesIterator e (begin_merged ()); ! e.at_end (); ++e) {
|
||||
output->insert (extended_edge (*e, ext_b, ext_e, ext_o, ext_i));
|
||||
}
|
||||
|
|
@ -339,7 +339,7 @@ AsIfFlatEdges::in (const Edges &other, bool invert) const
|
|||
op.insert (*o);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatEdges> new_region (new FlatEdges (false));
|
||||
std::unique_ptr<FlatEdges> new_region (new FlatEdges (false));
|
||||
|
||||
for (EdgesIterator o (begin_merged ()); ! o.at_end (); ++o) {
|
||||
if ((op.find (*o) == op.end ()) == invert) {
|
||||
|
|
@ -434,7 +434,7 @@ void AsIfFlatEdges::invalidate_bbox ()
|
|||
EdgesDelegate *
|
||||
AsIfFlatEdges::processed (const EdgeProcessorBase &filter) const
|
||||
{
|
||||
std::auto_ptr<FlatEdges> edges (new FlatEdges ());
|
||||
std::unique_ptr<FlatEdges> edges (new FlatEdges ());
|
||||
|
||||
if (filter.result_must_not_be_merged ()) {
|
||||
edges->set_merged_semantics (false);
|
||||
|
|
@ -456,7 +456,7 @@ AsIfFlatEdges::processed (const EdgeProcessorBase &filter) const
|
|||
EdgePairsDelegate *
|
||||
AsIfFlatEdges::processed_to_edge_pairs (const EdgeToEdgePairProcessorBase &filter) const
|
||||
{
|
||||
std::auto_ptr<FlatEdgePairs> edge_pairs (new FlatEdgePairs ());
|
||||
std::unique_ptr<FlatEdgePairs> edge_pairs (new FlatEdgePairs ());
|
||||
|
||||
if (filter.result_must_not_be_merged ()) {
|
||||
edge_pairs->set_merged_semantics (false);
|
||||
|
|
@ -478,7 +478,7 @@ AsIfFlatEdges::processed_to_edge_pairs (const EdgeToEdgePairProcessorBase &filte
|
|||
RegionDelegate *
|
||||
AsIfFlatEdges::processed_to_polygons (const EdgeToPolygonProcessorBase &filter) const
|
||||
{
|
||||
std::auto_ptr<FlatRegion> region (new FlatRegion ());
|
||||
std::unique_ptr<FlatRegion> region (new FlatRegion ());
|
||||
|
||||
if (filter.result_must_not_be_merged ()) {
|
||||
region->set_merged_semantics (false);
|
||||
|
|
@ -500,7 +500,7 @@ AsIfFlatEdges::processed_to_polygons (const EdgeToPolygonProcessorBase &filter)
|
|||
EdgesDelegate *
|
||||
AsIfFlatEdges::filtered (const EdgeFilterBase &filter) const
|
||||
{
|
||||
std::auto_ptr<FlatEdges> new_region (new FlatEdges ());
|
||||
std::unique_ptr<FlatEdges> new_region (new FlatEdges ());
|
||||
|
||||
for (EdgesIterator p (begin_merged ()); ! p.at_end (); ++p) {
|
||||
if (filter.selected (*p)) {
|
||||
|
|
@ -514,7 +514,7 @@ AsIfFlatEdges::filtered (const EdgeFilterBase &filter) const
|
|||
EdgePairsDelegate *
|
||||
AsIfFlatEdges::run_check (db::edge_relation_type rel, const Edges *other, db::Coord d, const db::EdgesCheckOptions &options) const
|
||||
{
|
||||
std::auto_ptr<FlatEdgePairs> result (new FlatEdgePairs ());
|
||||
std::unique_ptr<FlatEdgePairs> result (new FlatEdgePairs ());
|
||||
|
||||
db::box_scanner<db::Edge, size_t> scanner (report_progress (), progress_desc ());
|
||||
scanner.reserve (count () + (other ? other->count () : 0));
|
||||
|
|
@ -554,7 +554,7 @@ AsIfFlatEdges::run_check (db::edge_relation_type rel, const Edges *other, db::Co
|
|||
EdgesDelegate *
|
||||
AsIfFlatEdges::boolean (const Edges *other, EdgeBoolOp op) const
|
||||
{
|
||||
std::auto_ptr<FlatEdges> output (new FlatEdges (true));
|
||||
std::unique_ptr<FlatEdges> output (new FlatEdges (true));
|
||||
EdgeBooleanClusterCollectorToShapes cluster_collector (&output->raw_edges (), op);
|
||||
|
||||
db::box_scanner<db::Edge, size_t> scanner (report_progress (), progress_desc ());
|
||||
|
|
@ -610,7 +610,7 @@ AsIfFlatEdges::edge_region_op (const Region &other, bool outside, bool include_b
|
|||
ep.insert (*e, 1);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatEdges> output (new FlatEdges (false));
|
||||
std::unique_ptr<FlatEdges> output (new FlatEdges (false));
|
||||
db::EdgeShapeGenerator cc (output->raw_edges (), true /*clear*/);
|
||||
db::EdgePolygonOp op (outside, include_borders);
|
||||
ep.process (cc, op);
|
||||
|
|
@ -624,7 +624,7 @@ AsIfFlatEdges::add (const Edges &other) const
|
|||
FlatEdges *other_flat = dynamic_cast<FlatEdges *> (other.delegate ());
|
||||
if (other_flat) {
|
||||
|
||||
std::auto_ptr<FlatEdges> new_edges (new FlatEdges (*other_flat));
|
||||
std::unique_ptr<FlatEdges> new_edges (new FlatEdges (*other_flat));
|
||||
new_edges->set_is_merged (false);
|
||||
new_edges->invalidate_cache ();
|
||||
|
||||
|
|
@ -640,7 +640,7 @@ AsIfFlatEdges::add (const Edges &other) const
|
|||
|
||||
} else {
|
||||
|
||||
std::auto_ptr<FlatEdges> new_edges (new FlatEdges (false /*not merged*/));
|
||||
std::unique_ptr<FlatEdges> new_edges (new FlatEdges (false /*not merged*/));
|
||||
|
||||
size_t n = count () + other.count ();
|
||||
|
||||
|
|
|
|||
|
|
@ -129,7 +129,7 @@ AsIfFlatRegion::to_string (size_t nmax) const
|
|||
EdgesDelegate *
|
||||
AsIfFlatRegion::edges (const EdgeFilterBase *filter) const
|
||||
{
|
||||
std::auto_ptr<FlatEdges> result (new FlatEdges ());
|
||||
std::unique_ptr<FlatEdges> result (new FlatEdges ());
|
||||
|
||||
size_t n = 0;
|
||||
for (RegionIterator p (begin_merged ()); ! p.at_end (); ++p) {
|
||||
|
|
@ -156,7 +156,7 @@ AsIfFlatRegion::in (const Region &other, bool invert) const
|
|||
op.insert (*o);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion (false));
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion (false));
|
||||
|
||||
for (RegionIterator o (begin_merged ()); ! o.at_end (); ++o) {
|
||||
if ((op.find (*o) == op.end ()) == invert) {
|
||||
|
|
@ -298,7 +298,7 @@ void AsIfFlatRegion::invalidate_bbox ()
|
|||
RegionDelegate *
|
||||
AsIfFlatRegion::filtered (const PolygonFilterBase &filter) const
|
||||
{
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion ());
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion ());
|
||||
|
||||
for (RegionIterator p (begin_merged ()); ! p.at_end (); ++p) {
|
||||
if (filter.selected (*p)) {
|
||||
|
|
@ -312,7 +312,7 @@ AsIfFlatRegion::filtered (const PolygonFilterBase &filter) const
|
|||
RegionDelegate *
|
||||
AsIfFlatRegion::processed (const PolygonProcessorBase &filter) const
|
||||
{
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion ());
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion ());
|
||||
if (filter.result_must_not_be_merged ()) {
|
||||
new_region->set_merged_semantics (false);
|
||||
}
|
||||
|
|
@ -335,7 +335,7 @@ AsIfFlatRegion::processed (const PolygonProcessorBase &filter) const
|
|||
EdgesDelegate *
|
||||
AsIfFlatRegion::processed_to_edges (const PolygonToEdgeProcessorBase &filter) const
|
||||
{
|
||||
std::auto_ptr<FlatEdges> new_edges (new FlatEdges ());
|
||||
std::unique_ptr<FlatEdges> new_edges (new FlatEdges ());
|
||||
if (filter.result_must_not_be_merged ()) {
|
||||
new_edges->set_merged_semantics (false);
|
||||
}
|
||||
|
|
@ -358,7 +358,7 @@ AsIfFlatRegion::processed_to_edges (const PolygonToEdgeProcessorBase &filter) co
|
|||
EdgePairsDelegate *
|
||||
AsIfFlatRegion::processed_to_edge_pairs (const PolygonToEdgePairProcessorBase &filter) const
|
||||
{
|
||||
std::auto_ptr<FlatEdgePairs> new_edge_pairs (new FlatEdgePairs ());
|
||||
std::unique_ptr<FlatEdgePairs> new_edge_pairs (new FlatEdgePairs ());
|
||||
if (filter.result_must_not_be_merged ()) {
|
||||
new_edge_pairs->set_merged_semantics (false);
|
||||
}
|
||||
|
|
@ -407,7 +407,7 @@ AsIfFlatRegion::selected_interacting_generic (const Edges &other, bool inverse,
|
|||
std::vector<generic_shape_iterator<db::Edge> > others;
|
||||
others.push_back (counting ? other.begin_merged () : other.begin ());
|
||||
|
||||
std::auto_ptr<FlatRegion> output (new FlatRegion (merged_semantics ()));
|
||||
std::unique_ptr<FlatRegion> output (new FlatRegion (merged_semantics ()));
|
||||
std::vector<db::Shapes *> results;
|
||||
results.push_back (&output->raw_polygons ());
|
||||
|
||||
|
|
@ -423,7 +423,7 @@ AsIfFlatRegion::selected_interacting_generic (const Edges &other, bool inverse,
|
|||
scanner.reserve1 (count ());
|
||||
scanner.reserve2 (other.count ());
|
||||
|
||||
std::auto_ptr<FlatRegion> output (new FlatRegion (false));
|
||||
std::unique_ptr<FlatRegion> output (new FlatRegion (false));
|
||||
region_to_edge_interaction_filter<db::Polygon, db::Edge, ResultCountingInserter> filter (inserter, false, counting /*get all in counting mode*/);
|
||||
|
||||
AddressablePolygonDelivery p (begin_merged ());
|
||||
|
|
@ -483,7 +483,7 @@ AsIfFlatRegion::selected_interacting_generic (const Texts &other, bool inverse,
|
|||
std::vector<generic_shape_iterator<db::Text> > others;
|
||||
others.push_back (other.begin ());
|
||||
|
||||
std::auto_ptr<FlatRegion> output (new FlatRegion (merged_semantics ()));
|
||||
std::unique_ptr<FlatRegion> output (new FlatRegion (merged_semantics ()));
|
||||
std::vector<db::Shapes *> results;
|
||||
results.push_back (&output->raw_polygons ());
|
||||
|
||||
|
|
@ -522,7 +522,7 @@ AsIfFlatRegion::selected_interacting_generic (const Texts &other, bool inverse,
|
|||
|
||||
// select hits based on their count
|
||||
|
||||
std::auto_ptr<FlatRegion> output (new FlatRegion (true));
|
||||
std::unique_ptr<FlatRegion> output (new FlatRegion (true));
|
||||
|
||||
for (std::unordered_map<const db::Polygon *, size_t, std::ptr_hash_from_value<db::Polygon> >::const_iterator r = counted_results.begin (); r != counted_results.end (); ++r) {
|
||||
bool hit = r->second >= min_count && r->second <= max_count;
|
||||
|
|
@ -568,7 +568,7 @@ AsIfFlatRegion::selected_interacting_generic (const Region &other, int mode, boo
|
|||
std::vector<generic_shape_iterator<db::Polygon> > others;
|
||||
others.push_back ((mode < 0 || counting) ? other.begin_merged () : other.begin ());
|
||||
|
||||
std::auto_ptr<FlatRegion> output (new FlatRegion (merged_semantics ()));
|
||||
std::unique_ptr<FlatRegion> output (new FlatRegion (merged_semantics ()));
|
||||
std::vector<db::Shapes *> results;
|
||||
results.push_back (&output->raw_polygons ());
|
||||
|
||||
|
|
@ -658,7 +658,7 @@ AsIfFlatRegion::selected_interacting_generic (const Region &other, int mode, boo
|
|||
ep.process (es, id);
|
||||
id.finish ();
|
||||
|
||||
std::auto_ptr<FlatRegion> output (new FlatRegion (false));
|
||||
std::unique_ptr<FlatRegion> output (new FlatRegion (false));
|
||||
|
||||
std::map <size_t, size_t> interaction_counts;
|
||||
for (db::InteractionDetector::iterator i = id.begin (); i != id.end () ; ++i) {
|
||||
|
|
@ -706,7 +706,7 @@ AsIfFlatRegion::pull_generic (const Edges &other) const
|
|||
std::vector<generic_shape_iterator<db::Edge> > others;
|
||||
others.push_back (other.begin_merged ());
|
||||
|
||||
std::auto_ptr<FlatEdges> output (new FlatEdges (merged_semantics ()));
|
||||
std::unique_ptr<FlatEdges> output (new FlatEdges (merged_semantics ()));
|
||||
std::vector<db::Shapes *> results;
|
||||
results.push_back (&output->raw_edges ());
|
||||
|
||||
|
|
@ -720,7 +720,7 @@ AsIfFlatRegion::pull_generic (const Edges &other) const
|
|||
scanner.reserve1 (count ());
|
||||
scanner.reserve2 (other.count ());
|
||||
|
||||
std::auto_ptr<FlatEdges> output (new FlatEdges (false));
|
||||
std::unique_ptr<FlatEdges> output (new FlatEdges (false));
|
||||
region_to_edge_interaction_filter<db::Polygon, db::Edge, db::Shapes, db::Edge> filter (output->raw_edges (), false);
|
||||
|
||||
AddressablePolygonDelivery p (begin ());
|
||||
|
|
@ -756,7 +756,7 @@ AsIfFlatRegion::pull_generic (const Texts &other) const
|
|||
std::vector<generic_shape_iterator<db::Text> > others;
|
||||
others.push_back (other.begin ());
|
||||
|
||||
std::auto_ptr<FlatTexts> output (new FlatTexts ());
|
||||
std::unique_ptr<FlatTexts> output (new FlatTexts ());
|
||||
std::vector<db::Shapes *> results;
|
||||
results.push_back (&output->raw_texts ());
|
||||
|
||||
|
|
@ -775,7 +775,7 @@ AsIfFlatRegion::pull_generic (const Texts &other) const
|
|||
scanner.reserve1 (count ());
|
||||
scanner.reserve2 (other.count ());
|
||||
|
||||
std::auto_ptr<FlatTexts> output (new FlatTexts (false));
|
||||
std::unique_ptr<FlatTexts> output (new FlatTexts (false));
|
||||
region_to_text_interaction_filter<db::Polygon, db::Text, db::Shapes, db::Text> filter (output->raw_texts (), false);
|
||||
|
||||
AddressablePolygonDelivery p (begin ());
|
||||
|
|
@ -811,7 +811,7 @@ AsIfFlatRegion::pull_generic (const Region &other, int mode, bool touching) cons
|
|||
std::vector<generic_shape_iterator<db::Polygon> > others;
|
||||
others.push_back (other.begin_merged ());
|
||||
|
||||
std::auto_ptr<FlatRegion> output (new FlatRegion (merged_semantics ()));
|
||||
std::unique_ptr<FlatRegion> output (new FlatRegion (merged_semantics ()));
|
||||
std::vector<db::Shapes *> results;
|
||||
results.push_back (&output->raw_polygons ());
|
||||
|
||||
|
|
@ -849,7 +849,7 @@ AsIfFlatRegion::pull_generic (const Region &other, int mode, bool touching) cons
|
|||
ep.process (es, id);
|
||||
id.finish ();
|
||||
|
||||
std::auto_ptr<FlatRegion> output (new FlatRegion (false));
|
||||
std::unique_ptr<FlatRegion> output (new FlatRegion (false));
|
||||
|
||||
n = 0;
|
||||
std::set <size_t> selected;
|
||||
|
|
@ -914,7 +914,7 @@ AsIfFlatRegion::grid_check (db::Coord gx, db::Coord gy) const
|
|||
return new EmptyEdgePairs ();
|
||||
}
|
||||
|
||||
std::auto_ptr<db::FlatEdgePairs> res (new db::FlatEdgePairs ());
|
||||
std::unique_ptr<db::FlatEdgePairs> res (new db::FlatEdgePairs ());
|
||||
|
||||
for (RegionIterator p (begin_merged ()); ! p.at_end (); ++p) {
|
||||
produce_markers_for_grid_check (*p, db::UnitTrans (), gx, gy, res->raw_edge_pairs ());
|
||||
|
|
@ -984,7 +984,7 @@ template void AsIfFlatRegion::produce_markers_for_angle_check<db::UnitTrans> (co
|
|||
EdgePairsDelegate *
|
||||
AsIfFlatRegion::angle_check (double min, double max, bool inverse) const
|
||||
{
|
||||
std::auto_ptr<db::FlatEdgePairs> res (new db::FlatEdgePairs ());
|
||||
std::unique_ptr<db::FlatEdgePairs> res (new db::FlatEdgePairs ());
|
||||
|
||||
for (RegionIterator p (begin_merged ()); ! p.at_end (); ++p) {
|
||||
produce_markers_for_angle_check (*p, db::UnitTrans (), min, max, inverse, res->raw_edge_pairs ());
|
||||
|
|
@ -1000,7 +1000,7 @@ AsIfFlatRegion::snapped (db::Coord gx, db::Coord gy)
|
|||
throw tl::Exception (tl::to_string (tr ("Grid snap requires a positive grid value")));
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion (merged_semantics ()));
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion (merged_semantics ()));
|
||||
|
||||
gx = std::max (db::Coord (1), gx);
|
||||
gy = std::max (db::Coord (1), gy);
|
||||
|
|
@ -1025,7 +1025,7 @@ AsIfFlatRegion::scaled_and_snapped (db::Coord gx, db::Coord mx, db::Coord dx, db
|
|||
throw tl::Exception (tl::to_string (tr ("Scale and snap requires positive and non-null magnification or divisor values")));
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion (merged_semantics ()));
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion (merged_semantics ()));
|
||||
|
||||
gx = std::max (db::Coord (1), gx);
|
||||
gy = std::max (db::Coord (1), gy);
|
||||
|
|
@ -1073,7 +1073,7 @@ void region_cop_impl (AsIfFlatRegion *region, db::Shapes *output_to, db::Compoun
|
|||
EdgePairsDelegate *
|
||||
AsIfFlatRegion::cop_to_edge_pairs (db::CompoundRegionOperationNode &node)
|
||||
{
|
||||
std::auto_ptr<FlatEdgePairs> output (new FlatEdgePairs ());
|
||||
std::unique_ptr<FlatEdgePairs> output (new FlatEdgePairs ());
|
||||
region_cop_impl<db::EdgePair> (this, &output->raw_edge_pairs (), node);
|
||||
return output.release ();
|
||||
}
|
||||
|
|
@ -1081,7 +1081,7 @@ AsIfFlatRegion::cop_to_edge_pairs (db::CompoundRegionOperationNode &node)
|
|||
RegionDelegate *
|
||||
AsIfFlatRegion::cop_to_region (db::CompoundRegionOperationNode &node)
|
||||
{
|
||||
std::auto_ptr<FlatRegion> output (new FlatRegion ());
|
||||
std::unique_ptr<FlatRegion> output (new FlatRegion ());
|
||||
region_cop_impl<db::Polygon> (this, &output->raw_polygons (), node);
|
||||
return output.release ();
|
||||
}
|
||||
|
|
@ -1089,7 +1089,7 @@ AsIfFlatRegion::cop_to_region (db::CompoundRegionOperationNode &node)
|
|||
EdgesDelegate *
|
||||
AsIfFlatRegion::cop_to_edges (db::CompoundRegionOperationNode &node)
|
||||
{
|
||||
std::auto_ptr<FlatEdges> output (new FlatEdges ());
|
||||
std::unique_ptr<FlatEdges> output (new FlatEdges ());
|
||||
region_cop_impl<db::Edge> (this, &output->raw_edges (), node);
|
||||
return output.release ();
|
||||
}
|
||||
|
|
@ -1188,7 +1188,7 @@ AsIfFlatRegion::run_check (db::edge_relation_type rel, bool different_polygons,
|
|||
|
||||
db::check_local_operation<db::Polygon, db::Polygon> op (check, different_polygons, has_other, other_is_merged, options);
|
||||
|
||||
std::auto_ptr<FlatEdgePairs> output (new FlatEdgePairs ());
|
||||
std::unique_ptr<FlatEdgePairs> output (new FlatEdgePairs ());
|
||||
std::vector<db::Shapes *> results;
|
||||
results.push_back (&output->raw_edge_pairs ());
|
||||
|
||||
|
|
@ -1200,7 +1200,7 @@ AsIfFlatRegion::run_check (db::edge_relation_type rel, bool different_polygons,
|
|||
// not supported in this implementation
|
||||
tl_assert (! m_options.no_opposite);
|
||||
|
||||
std::auto_ptr<FlatEdgePairs> result (new FlatEdgePairs ());
|
||||
std::unique_ptr<FlatEdgePairs> result (new FlatEdgePairs ());
|
||||
|
||||
db::box_scanner<db::Polygon, size_t> scanner (report_progress (), progress_desc ());
|
||||
scanner.reserve (count () + (other ? other->count () : 0));
|
||||
|
|
@ -1248,7 +1248,7 @@ AsIfFlatRegion::run_check (db::edge_relation_type rel, bool different_polygons,
|
|||
EdgePairsDelegate *
|
||||
AsIfFlatRegion::run_single_polygon_check (db::edge_relation_type rel, db::Coord d, const RegionCheckOptions &options) const
|
||||
{
|
||||
std::auto_ptr<FlatEdgePairs> result (new FlatEdgePairs ());
|
||||
std::unique_ptr<FlatEdgePairs> result (new FlatEdgePairs ());
|
||||
|
||||
EdgeRelationFilter check (rel, d, options.metrics);
|
||||
check.set_include_zero (false);
|
||||
|
|
@ -1307,7 +1307,7 @@ AsIfFlatRegion::merged (bool min_coherence, unsigned int min_wc) const
|
|||
ep.insert (*p, n);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion (true));
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion (true));
|
||||
|
||||
// and run the merge step
|
||||
db::MergeOp op (min_wc);
|
||||
|
|
@ -1355,7 +1355,7 @@ AsIfFlatRegion::sized (coord_type dx, coord_type dy, unsigned int mode) const
|
|||
} else if (! merged_semantics () || is_merged ()) {
|
||||
|
||||
// Generic case
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion (false /*output isn't merged*/));
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion (false /*output isn't merged*/));
|
||||
|
||||
db::ShapeGenerator pc (new_region->raw_polygons (), false);
|
||||
db::PolygonGenerator pg (pc, false, true);
|
||||
|
|
@ -1385,7 +1385,7 @@ AsIfFlatRegion::sized (coord_type dx, coord_type dy, unsigned int mode) const
|
|||
ep.insert (*p, n);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion (false /*output isn't merged*/));
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion (false /*output isn't merged*/));
|
||||
db::ShapeGenerator pc (new_region->raw_polygons (), true /*clear*/);
|
||||
db::PolygonGenerator pg2 (pc, false /*don't resolve holes*/, true /*min. coherence*/);
|
||||
db::SizingPolygonFilter siz (pg2, dx, dy, mode);
|
||||
|
|
@ -1417,7 +1417,7 @@ AsIfFlatRegion::and_with (const Region &other) const
|
|||
|
||||
// map AND with box to clip ..
|
||||
db::Box b = bbox ();
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion (false));
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion (false));
|
||||
|
||||
std::vector<db::Polygon> clipped;
|
||||
for (RegionIterator p (other.begin ()); ! p.at_end (); ++p) {
|
||||
|
|
@ -1432,7 +1432,7 @@ AsIfFlatRegion::and_with (const Region &other) const
|
|||
|
||||
// map AND with box to clip ..
|
||||
db::Box b = other.bbox ();
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion (false));
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion (false));
|
||||
|
||||
std::vector<db::Polygon> clipped;
|
||||
for (RegionIterator p (begin ()); ! p.at_end (); ++p) {
|
||||
|
|
@ -1474,7 +1474,7 @@ AsIfFlatRegion::and_with (const Region &other) const
|
|||
ep.insert (*p, n);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion (true));
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion (true));
|
||||
db::BooleanOp op (db::BooleanOp::And);
|
||||
db::ShapeGenerator pc (new_region->raw_polygons (), true /*clear*/);
|
||||
db::PolygonGenerator pg (pc, false /*don't resolve holes*/, min_coherence ());
|
||||
|
|
@ -1529,7 +1529,7 @@ AsIfFlatRegion::not_with (const Region &other) const
|
|||
ep.insert (*p, n);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion (true));
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion (true));
|
||||
db::BooleanOp op (db::BooleanOp::ANotB);
|
||||
db::ShapeGenerator pc (new_region->raw_polygons (), true /*clear*/);
|
||||
db::PolygonGenerator pg (pc, false /*don't resolve holes*/, min_coherence ());
|
||||
|
|
@ -1585,12 +1585,12 @@ AsIfFlatRegion::andnot_with (const Region &other) const
|
|||
ep.insert (*p, n);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatRegion> new_region1 (new FlatRegion (true));
|
||||
std::unique_ptr<FlatRegion> new_region1 (new FlatRegion (true));
|
||||
db::BooleanOp op1 (db::BooleanOp::And);
|
||||
db::ShapeGenerator pc1 (new_region1->raw_polygons (), true /*clear*/);
|
||||
db::PolygonGenerator pg1 (pc1, false /*don't resolve holes*/, min_coherence ());
|
||||
|
||||
std::auto_ptr<FlatRegion> new_region2 (new FlatRegion (true));
|
||||
std::unique_ptr<FlatRegion> new_region2 (new FlatRegion (true));
|
||||
db::BooleanOp op2 (db::BooleanOp::ANotB);
|
||||
db::ShapeGenerator pc2 (new_region2->raw_polygons (), true /*clear*/);
|
||||
db::PolygonGenerator pg2 (pc2, false /*don't resolve holes*/, min_coherence ());
|
||||
|
|
@ -1647,7 +1647,7 @@ AsIfFlatRegion::xor_with (const Region &other) const
|
|||
ep.insert (*p, n);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion (true));
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion (true));
|
||||
db::BooleanOp op (db::BooleanOp::Xor);
|
||||
db::ShapeGenerator pc (new_region->raw_polygons (), true /*clear*/);
|
||||
db::PolygonGenerator pg (pc, false /*don't resolve holes*/, min_coherence ());
|
||||
|
|
@ -1701,7 +1701,7 @@ AsIfFlatRegion::or_with (const Region &other) const
|
|||
ep.insert (*p, n);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion (true));
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion (true));
|
||||
db::BooleanOp op (db::BooleanOp::Or);
|
||||
db::ShapeGenerator pc (new_region->raw_polygons (), true /*clear*/);
|
||||
db::PolygonGenerator pg (pc, false /*don't resolve holes*/, min_coherence ());
|
||||
|
|
@ -1718,7 +1718,7 @@ AsIfFlatRegion::add (const Region &other) const
|
|||
FlatRegion *other_flat = dynamic_cast<FlatRegion *> (other.delegate ());
|
||||
if (other_flat) {
|
||||
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion (*other_flat));
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion (*other_flat));
|
||||
new_region->set_is_merged (false);
|
||||
new_region->invalidate_cache ();
|
||||
|
||||
|
|
@ -1734,7 +1734,7 @@ AsIfFlatRegion::add (const Region &other) const
|
|||
|
||||
} else {
|
||||
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion (false /*not merged*/));
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion (false /*not merged*/));
|
||||
|
||||
size_t n = count () + other.count ();
|
||||
|
||||
|
|
|
|||
|
|
@ -94,7 +94,7 @@ AsIfFlatTexts::in (const Texts &other, bool invert) const
|
|||
op.insert (*o);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatTexts> new_texts (new FlatTexts ());
|
||||
std::unique_ptr<FlatTexts> new_texts (new FlatTexts ());
|
||||
|
||||
for (TextsIterator o (begin ()); ! o.at_end (); ++o) {
|
||||
if ((op.find (*o) == op.end ()) == invert) {
|
||||
|
|
@ -153,7 +153,7 @@ void AsIfFlatTexts::invalidate_bbox ()
|
|||
TextsDelegate *
|
||||
AsIfFlatTexts::filtered (const TextFilterBase &filter) const
|
||||
{
|
||||
std::auto_ptr<FlatTexts> new_texts (new FlatTexts ());
|
||||
std::unique_ptr<FlatTexts> new_texts (new FlatTexts ());
|
||||
|
||||
for (TextsIterator p (begin ()); ! p.at_end (); ++p) {
|
||||
if (filter.selected (*p)) {
|
||||
|
|
@ -167,7 +167,7 @@ AsIfFlatTexts::filtered (const TextFilterBase &filter) const
|
|||
RegionDelegate *
|
||||
AsIfFlatTexts::processed_to_polygons (const TextToPolygonProcessorBase &filter) const
|
||||
{
|
||||
std::auto_ptr<FlatRegion> region (new FlatRegion ());
|
||||
std::unique_ptr<FlatRegion> region (new FlatRegion ());
|
||||
|
||||
if (filter.result_must_not_be_merged ()) {
|
||||
region->set_merged_semantics (false);
|
||||
|
|
@ -189,7 +189,7 @@ AsIfFlatTexts::processed_to_polygons (const TextToPolygonProcessorBase &filter)
|
|||
RegionDelegate *
|
||||
AsIfFlatTexts::polygons (db::Coord e) const
|
||||
{
|
||||
std::auto_ptr<FlatRegion> output (new FlatRegion ());
|
||||
std::unique_ptr<FlatRegion> output (new FlatRegion ());
|
||||
|
||||
for (TextsIterator tp (begin ()); ! tp.at_end (); ++tp) {
|
||||
db::Box box = tp->box ();
|
||||
|
|
@ -203,7 +203,7 @@ AsIfFlatTexts::polygons (db::Coord e) const
|
|||
EdgesDelegate *
|
||||
AsIfFlatTexts::edges () const
|
||||
{
|
||||
std::auto_ptr<FlatEdges> output (new FlatEdges ());
|
||||
std::unique_ptr<FlatEdges> output (new FlatEdges ());
|
||||
|
||||
for (TextsIterator tp (begin ()); ! tp.at_end (); ++tp) {
|
||||
db::Box box = tp->box ();
|
||||
|
|
@ -219,7 +219,7 @@ AsIfFlatTexts::add (const Texts &other) const
|
|||
FlatTexts *other_flat = dynamic_cast<FlatTexts *> (other.delegate ());
|
||||
if (other_flat) {
|
||||
|
||||
std::auto_ptr<FlatTexts> new_texts (new FlatTexts (*other_flat));
|
||||
std::unique_ptr<FlatTexts> new_texts (new FlatTexts (*other_flat));
|
||||
new_texts->invalidate_cache ();
|
||||
|
||||
size_t n = new_texts->raw_texts ().size () + count ();
|
||||
|
|
@ -234,7 +234,7 @@ AsIfFlatTexts::add (const Texts &other) const
|
|||
|
||||
} else {
|
||||
|
||||
std::auto_ptr<FlatTexts> new_texts (new FlatTexts ());
|
||||
std::unique_ptr<FlatTexts> new_texts (new FlatTexts ());
|
||||
|
||||
size_t n = count () + other.count ();
|
||||
|
||||
|
|
@ -342,7 +342,7 @@ AsIfFlatTexts::selected_interacting_generic (const Region &other, bool inverse)
|
|||
scanner.insert2 (p.operator-> (), 1);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatTexts> output (new FlatTexts ());
|
||||
std::unique_ptr<FlatTexts> output (new FlatTexts ());
|
||||
|
||||
if (! inverse) {
|
||||
|
||||
|
|
@ -388,7 +388,7 @@ AsIfFlatTexts::pull_generic (const Region &other) const
|
|||
scanner.insert2 (p.operator-> (), 1);
|
||||
}
|
||||
|
||||
std::auto_ptr<FlatRegion> output (new FlatRegion (true));
|
||||
std::unique_ptr<FlatRegion> output (new FlatRegion (true));
|
||||
|
||||
text_to_region_interaction_filter<FlatRegion, db::Text> filter (*output);
|
||||
scanner.process (filter, 1, db::box_convert<db::Text> (), db::box_convert<db::Polygon> ());
|
||||
|
|
|
|||
|
|
@ -354,7 +354,7 @@ private:
|
|||
iterator_type current = m_pp.begin ();
|
||||
iterator_type future = m_pp.begin ();
|
||||
|
||||
std::auto_ptr<tl::RelativeProgress> progress (0);
|
||||
std::unique_ptr<tl::RelativeProgress> progress;
|
||||
if (m_report_progress) {
|
||||
if (m_progress_desc.empty ()) {
|
||||
progress.reset (new tl::RelativeProgress (tl::to_string (tr ("Processing")), m_pp.size (), 1000));
|
||||
|
|
@ -767,7 +767,7 @@ private:
|
|||
iterator_type2 current2 = m_pp2.begin ();
|
||||
iterator_type2 future2 = m_pp2.begin ();
|
||||
|
||||
std::auto_ptr<tl::RelativeProgress> progress (0);
|
||||
std::unique_ptr<tl::RelativeProgress> progress;
|
||||
if (m_report_progress) {
|
||||
if (m_progress_desc.empty ()) {
|
||||
progress.reset (new tl::RelativeProgress (tl::to_string (tr ("Processing")), m_pp1.size () + m_pp2.size (), 1000));
|
||||
|
|
|
|||
|
|
@ -598,7 +598,7 @@ DeepEdges::apply_filter (const EdgeFilterBase &filter) const
|
|||
{
|
||||
const db::DeepLayer &edges = filter.requires_raw_input () ? deep_layer () : merged_deep_layer ();
|
||||
|
||||
std::auto_ptr<VariantsCollectorBase> vars;
|
||||
std::unique_ptr<VariantsCollectorBase> vars;
|
||||
if (filter.vars ()) {
|
||||
|
||||
vars.reset (new db::VariantsCollectorBase (filter.vars ()));
|
||||
|
|
@ -614,7 +614,7 @@ DeepEdges::apply_filter (const EdgeFilterBase &filter) const
|
|||
db::Layout &layout = const_cast<db::Layout &> (edges.layout ());
|
||||
std::map<db::cell_index_type, std::map<db::ICplxTrans, db::Shapes> > to_commit;
|
||||
|
||||
std::auto_ptr<db::DeepEdges> res (new db::DeepEdges (edges.derived ()));
|
||||
std::unique_ptr<db::DeepEdges> res (new db::DeepEdges (edges.derived ()));
|
||||
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
|
||||
|
||||
const db::Shapes &s = c->shapes (edges.layer ());
|
||||
|
|
@ -681,7 +681,7 @@ EdgesDelegate *DeepEdges::merged () const
|
|||
|
||||
db::Layout &layout = const_cast<db::Layout &> (m_merged_edges.layout ());
|
||||
|
||||
std::auto_ptr<db::DeepEdges> res (new db::DeepEdges (m_merged_edges.derived ()));
|
||||
std::unique_ptr<db::DeepEdges> res (new db::DeepEdges (m_merged_edges.derived ()));
|
||||
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
|
||||
c->shapes (res->deep_layer ().layer ()) = c->shapes (m_merged_edges.layer ());
|
||||
}
|
||||
|
|
@ -972,7 +972,7 @@ RegionDelegate *DeepEdges::extended (coord_type ext_b, coord_type ext_e, coord_t
|
|||
{
|
||||
const db::DeepLayer &edges = merged_deep_layer ();
|
||||
|
||||
std::auto_ptr<db::DeepRegion> res (new db::DeepRegion (edges.derived ()));
|
||||
std::unique_ptr<db::DeepRegion> res (new db::DeepRegion (edges.derived ()));
|
||||
|
||||
db::Layout &layout = const_cast<db::Layout &> (edges.layout ());
|
||||
db::Cell &top_cell = const_cast<db::Cell &> (edges.initial_cell ());
|
||||
|
|
@ -1358,7 +1358,7 @@ public:
|
|||
EdgesDelegate *
|
||||
DeepEdges::selected_interacting_generic (const Region &other, bool inverse) const
|
||||
{
|
||||
std::auto_ptr<db::DeepRegion> dr_holder;
|
||||
std::unique_ptr<db::DeepRegion> dr_holder;
|
||||
const db::DeepRegion *other_deep = dynamic_cast<const db::DeepRegion *> (other.delegate ());
|
||||
if (! other_deep) {
|
||||
// if the other region isn't deep, turn into a top-level only deep region to facilitate re-hierarchisation
|
||||
|
|
@ -1384,7 +1384,7 @@ DeepEdges::selected_interacting_generic (const Region &other, bool inverse) cons
|
|||
EdgesDelegate *
|
||||
DeepEdges::selected_interacting_generic (const Edges &other, bool inverse) const
|
||||
{
|
||||
std::auto_ptr<db::DeepEdges> dr_holder;
|
||||
std::unique_ptr<db::DeepEdges> dr_holder;
|
||||
const db::DeepEdges *other_deep = dynamic_cast<const db::DeepEdges *> (other.delegate ());
|
||||
if (! other_deep) {
|
||||
// if the other edge collection isn't deep, turn into a top-level only deep edge collection to facilitate re-hierarchisation
|
||||
|
|
@ -1409,7 +1409,7 @@ DeepEdges::selected_interacting_generic (const Edges &other, bool inverse) const
|
|||
|
||||
RegionDelegate *DeepEdges::pull_generic (const Region &other) const
|
||||
{
|
||||
std::auto_ptr<db::DeepRegion> dr_holder;
|
||||
std::unique_ptr<db::DeepRegion> dr_holder;
|
||||
const db::DeepRegion *other_deep = dynamic_cast<const db::DeepRegion *> (other.delegate ());
|
||||
if (! other_deep) {
|
||||
// if the other region isn't deep, turn into a top-level only deep region to facilitate re-hierarchisation
|
||||
|
|
@ -1435,7 +1435,7 @@ RegionDelegate *DeepEdges::pull_generic (const Region &other) const
|
|||
|
||||
EdgesDelegate *DeepEdges::pull_generic (const Edges &other) const
|
||||
{
|
||||
std::auto_ptr<db::DeepEdges> dr_holder;
|
||||
std::unique_ptr<db::DeepEdges> dr_holder;
|
||||
const db::DeepEdges *other_deep = dynamic_cast<const db::DeepEdges *> (other.delegate ());
|
||||
if (! other_deep) {
|
||||
// if the other edge collection isn't deep, turn into a top-level only deep edge collection to facilitate re-hierarchisation
|
||||
|
|
@ -1572,7 +1572,7 @@ DeepEdges::run_check (db::edge_relation_type rel, const Edges *other, db::Coord
|
|||
check.set_min_projection (options.min_projection);
|
||||
check.set_max_projection (options.max_projection);
|
||||
|
||||
std::auto_ptr<db::DeepEdgePairs> res (new db::DeepEdgePairs (edges.derived ()));
|
||||
std::unique_ptr<db::DeepEdgePairs> res (new db::DeepEdgePairs (edges.derived ()));
|
||||
|
||||
db::EdgesCheckLocalOperation op (check, other_deep != 0);
|
||||
|
||||
|
|
|
|||
|
|
@ -869,7 +869,7 @@ DeepRegion::grid_check (db::Coord gx, db::Coord gy) const
|
|||
vars.collect (layout, polygons.initial_cell ());
|
||||
|
||||
std::map<db::cell_index_type, std::map<db::ICplxTrans, db::Shapes> > to_commit;
|
||||
std::auto_ptr<db::DeepEdgePairs> res (new db::DeepEdgePairs (polygons.derived ()));
|
||||
std::unique_ptr<db::DeepEdgePairs> res (new db::DeepEdgePairs (polygons.derived ()));
|
||||
|
||||
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
|
||||
|
||||
|
|
@ -910,7 +910,7 @@ DeepRegion::angle_check (double min, double max, bool inverse) const
|
|||
const db::DeepLayer &polygons = merged_deep_layer ();
|
||||
db::Layout &layout = const_cast<db::Layout &> (polygons.layout ());
|
||||
|
||||
std::auto_ptr<db::DeepEdgePairs> res (new db::DeepEdgePairs (polygons.derived ()));
|
||||
std::unique_ptr<db::DeepEdgePairs> res (new db::DeepEdgePairs (polygons.derived ()));
|
||||
|
||||
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
|
||||
|
||||
|
|
@ -956,7 +956,7 @@ DeepRegion::snapped (db::Coord gx, db::Coord gy)
|
|||
db::Layout &layout = const_cast<db::Layout &> (polygons.layout ());
|
||||
std::vector<db::Point> heap;
|
||||
|
||||
std::auto_ptr<db::DeepRegion> res (new db::DeepRegion (polygons.derived ()));
|
||||
std::unique_ptr<db::DeepRegion> res (new db::DeepRegion (polygons.derived ()));
|
||||
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
|
||||
|
||||
const std::map<db::ICplxTrans, size_t> &v = vars.variants (c->cell_index ());
|
||||
|
|
@ -987,7 +987,7 @@ DeepRegion::edges (const EdgeFilterBase *filter) const
|
|||
{
|
||||
const db::DeepLayer &polygons = merged_deep_layer ();
|
||||
|
||||
std::auto_ptr<VariantsCollectorBase> vars;
|
||||
std::unique_ptr<VariantsCollectorBase> vars;
|
||||
|
||||
if (filter && filter->vars ()) {
|
||||
|
||||
|
|
@ -1002,7 +1002,7 @@ DeepRegion::edges (const EdgeFilterBase *filter) const
|
|||
|
||||
db::Layout &layout = const_cast<db::Layout &> (polygons.layout ());
|
||||
|
||||
std::auto_ptr<db::DeepEdges> res (new db::DeepEdges (polygons.derived ()));
|
||||
std::unique_ptr<db::DeepEdges> res (new db::DeepEdges (polygons.derived ()));
|
||||
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
|
||||
|
||||
db::ICplxTrans tr;
|
||||
|
|
@ -1078,7 +1078,7 @@ DeepRegion::apply_filter (const PolygonFilterBase &filter) const
|
|||
{
|
||||
const db::DeepLayer &polygons = filter.requires_raw_input () ? deep_layer () : merged_deep_layer ();
|
||||
|
||||
std::auto_ptr<VariantsCollectorBase> vars;
|
||||
std::unique_ptr<VariantsCollectorBase> vars;
|
||||
if (filter.vars ()) {
|
||||
|
||||
vars.reset (new db::VariantsCollectorBase (filter.vars ()));
|
||||
|
|
@ -1094,7 +1094,7 @@ DeepRegion::apply_filter (const PolygonFilterBase &filter) const
|
|||
db::Layout &layout = const_cast<db::Layout &> (polygons.layout ());
|
||||
std::map<db::cell_index_type, std::map<db::ICplxTrans, db::Shapes> > to_commit;
|
||||
|
||||
std::auto_ptr<db::DeepRegion> res (new db::DeepRegion (polygons.derived ()));
|
||||
std::unique_ptr<db::DeepRegion> res (new db::DeepRegion (polygons.derived ()));
|
||||
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
|
||||
|
||||
const db::Shapes &s = c->shapes (polygons.layer ());
|
||||
|
|
@ -1174,7 +1174,7 @@ DeepRegion::merged () const
|
|||
|
||||
db::Layout &layout = const_cast<db::Layout &> (m_merged_polygons.layout ());
|
||||
|
||||
std::auto_ptr<db::DeepRegion> res (new db::DeepRegion (m_merged_polygons.derived ()));
|
||||
std::unique_ptr<db::DeepRegion> res (new db::DeepRegion (m_merged_polygons.derived ()));
|
||||
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
|
||||
c->shapes (res->deep_layer ().layer ()) = c->shapes (m_merged_polygons.layer ());
|
||||
}
|
||||
|
|
@ -1242,7 +1242,7 @@ DeepRegion::sized (coord_type d, unsigned int mode) const
|
|||
// NOTE: m_merged_polygons is mutable, so why is the const_cast needed?
|
||||
const_cast<db::DeepLayer &> (polygons).separate_variants (vars);
|
||||
|
||||
std::auto_ptr<db::DeepRegion> res (new db::DeepRegion (polygons.derived ()));
|
||||
std::unique_ptr<db::DeepRegion> res (new db::DeepRegion (polygons.derived ()));
|
||||
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
|
||||
|
||||
const std::map<db::ICplxTrans, size_t> &v = vars.variants (c->cell_index ());
|
||||
|
|
@ -1297,7 +1297,7 @@ DeepRegion::sized (coord_type dx, coord_type dy, unsigned int mode) const
|
|||
// NOTE: m_merged_polygons is mutable, so why is the const_cast needed?
|
||||
const_cast<db::DeepLayer &> (polygons).separate_variants (vars);
|
||||
|
||||
std::auto_ptr<db::DeepRegion> res (new db::DeepRegion (polygons.derived ()));
|
||||
std::unique_ptr<db::DeepRegion> res (new db::DeepRegion (polygons.derived ()));
|
||||
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
|
||||
|
||||
const std::map<db::ICplxTrans, size_t> &v = vars.variants (c->cell_index ());
|
||||
|
|
@ -1384,7 +1384,7 @@ Output *region_cop_impl (DeepRegion *region, db::CompoundRegionOperationNode &no
|
|||
|
||||
}
|
||||
|
||||
std::auto_ptr<Output> res (new Output (polygons.derived ()));
|
||||
std::unique_ptr<Output> res (new Output (polygons.derived ()));
|
||||
compound_local_operation<db::PolygonRef, db::PolygonRef, TR> op (&node);
|
||||
proc.run (&op, polygons.layer (), other_layers, res->deep_layer ().layer ());
|
||||
|
||||
|
|
@ -1453,7 +1453,7 @@ DeepRegion::run_check (db::edge_relation_type rel, bool different_polygons, cons
|
|||
check.set_min_projection (options.min_projection);
|
||||
check.set_max_projection (options.max_projection);
|
||||
|
||||
std::auto_ptr<db::DeepEdgePairs> res (new db::DeepEdgePairs (polygons.derived ()));
|
||||
std::unique_ptr<db::DeepEdgePairs> res (new db::DeepEdgePairs (polygons.derived ()));
|
||||
|
||||
db::CheckLocalOperation op (check, different_polygons, other_deep != 0, other_is_merged, options);
|
||||
|
||||
|
|
@ -1486,7 +1486,7 @@ DeepRegion::run_single_polygon_check (db::edge_relation_type rel, db::Coord d, c
|
|||
|
||||
db::Layout &layout = const_cast<db::Layout &> (polygons.layout ());
|
||||
|
||||
std::auto_ptr<db::DeepEdgePairs> res (new db::DeepEdgePairs (polygons.derived ()));
|
||||
std::unique_ptr<db::DeepEdgePairs> res (new db::DeepEdgePairs (polygons.derived ()));
|
||||
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
|
||||
|
||||
const db::Shapes &shapes = c->shapes (polygons.layer ());
|
||||
|
|
@ -1519,7 +1519,7 @@ DeepRegion::selected_interacting_generic (const Region &other, int mode, bool to
|
|||
// with these flag set to true, the resulting polygons are broken again.
|
||||
bool split_after = false;
|
||||
|
||||
std::auto_ptr<db::DeepRegion> dr_holder;
|
||||
std::unique_ptr<db::DeepRegion> dr_holder;
|
||||
const db::DeepRegion *other_deep = dynamic_cast<const db::DeepRegion *> (other.delegate ());
|
||||
if (! other_deep) {
|
||||
// if the other region isn't deep, turn into a top-level only deep region to facilitate re-hierarchisation
|
||||
|
|
@ -1560,7 +1560,7 @@ DeepRegion::selected_interacting_generic (const Edges &other, bool inverse, size
|
|||
// with these flag set to true, the resulting polygons are broken again.
|
||||
bool split_after = false;
|
||||
|
||||
std::auto_ptr<db::DeepEdges> dr_holder;
|
||||
std::unique_ptr<db::DeepEdges> dr_holder;
|
||||
const db::DeepEdges *other_deep = dynamic_cast<const db::DeepEdges *> (other.delegate ());
|
||||
if (! other_deep) {
|
||||
// if the other region isn't deep, turn into a top-level only deep region to facilitate re-hierarchisation
|
||||
|
|
@ -1597,7 +1597,7 @@ DeepRegion::pull_generic (const Region &other, int mode, bool touching) const
|
|||
// with these flag set to true, the resulting polygons are broken again.
|
||||
bool split_after = false;
|
||||
|
||||
std::auto_ptr<db::DeepRegion> dr_holder;
|
||||
std::unique_ptr<db::DeepRegion> dr_holder;
|
||||
const db::DeepRegion *other_deep = dynamic_cast<const db::DeepRegion *> (other.delegate ());
|
||||
if (! other_deep) {
|
||||
// if the other region isn't deep, turn into a top-level only deep region to facilitate re-hierarchisation
|
||||
|
|
@ -1633,7 +1633,7 @@ DeepRegion::pull_generic (const Region &other, int mode, bool touching) const
|
|||
EdgesDelegate *
|
||||
DeepRegion::pull_generic (const Edges &other) const
|
||||
{
|
||||
std::auto_ptr<db::DeepEdges> dr_holder;
|
||||
std::unique_ptr<db::DeepEdges> dr_holder;
|
||||
const db::DeepEdges *other_deep = dynamic_cast<const db::DeepEdges *> (other.delegate ());
|
||||
if (! other_deep) {
|
||||
// if the other region isn't deep, turn into a top-level only deep region to facilitate re-hierarchisation
|
||||
|
|
@ -1662,7 +1662,7 @@ DeepRegion::pull_generic (const Edges &other) const
|
|||
TextsDelegate *
|
||||
DeepRegion::pull_generic (const Texts &other) const
|
||||
{
|
||||
std::auto_ptr<db::DeepTexts> dr_holder;
|
||||
std::unique_ptr<db::DeepTexts> dr_holder;
|
||||
const db::DeepTexts *other_deep = dynamic_cast<const db::DeepTexts *> (other.delegate ());
|
||||
if (! other_deep) {
|
||||
// if the other region isn't deep, turn into a top-level only deep region to facilitate re-hierarchisation
|
||||
|
|
@ -1694,7 +1694,7 @@ DeepRegion::selected_interacting_generic (const Texts &other, bool inverse, size
|
|||
// with these flag set to true, the resulting polygons are broken again.
|
||||
bool split_after = false;
|
||||
|
||||
std::auto_ptr<db::DeepTexts> dr_holder;
|
||||
std::unique_ptr<db::DeepTexts> dr_holder;
|
||||
const db::DeepTexts *other_deep = dynamic_cast<const db::DeepTexts *> (other.delegate ());
|
||||
if (! other_deep) {
|
||||
// if the other region isn't deep, turn into a top-level only deep region to facilitate re-hierarchisation
|
||||
|
|
|
|||
|
|
@ -302,7 +302,7 @@ DeepTexts *DeepTexts::apply_filter (const TextFilterBase &filter) const
|
|||
{
|
||||
const db::DeepLayer &texts = deep_layer ();
|
||||
|
||||
std::auto_ptr<VariantsCollectorBase> vars;
|
||||
std::unique_ptr<VariantsCollectorBase> vars;
|
||||
if (filter.vars ()) {
|
||||
|
||||
vars.reset (new db::VariantsCollectorBase (filter.vars ()));
|
||||
|
|
@ -318,7 +318,7 @@ DeepTexts *DeepTexts::apply_filter (const TextFilterBase &filter) const
|
|||
db::Layout &layout = const_cast<db::Layout &> (texts.layout ());
|
||||
std::map<db::cell_index_type, std::map<db::ICplxTrans, db::Shapes> > to_commit;
|
||||
|
||||
std::auto_ptr<db::DeepTexts> res (new db::DeepTexts (texts.derived ()));
|
||||
std::unique_ptr<db::DeepTexts> res (new db::DeepTexts (texts.derived ()));
|
||||
for (db::Layout::iterator c = layout.begin (); c != layout.end (); ++c) {
|
||||
|
||||
const db::Shapes &s = c->shapes (texts.layer ());
|
||||
|
|
@ -610,7 +610,7 @@ public:
|
|||
TextsDelegate *
|
||||
DeepTexts::selected_interacting_generic (const Region &other, bool inverse) const
|
||||
{
|
||||
std::auto_ptr<db::DeepRegion> dr_holder;
|
||||
std::unique_ptr<db::DeepRegion> dr_holder;
|
||||
const db::DeepRegion *other_deep = dynamic_cast<const db::DeepRegion *> (other.delegate ());
|
||||
if (! other_deep) {
|
||||
// if the other region isn't deep, turn into a top-level only deep region to facilitate re-hierarchisation
|
||||
|
|
@ -635,7 +635,7 @@ DeepTexts::selected_interacting_generic (const Region &other, bool inverse) cons
|
|||
|
||||
RegionDelegate *DeepTexts::pull_generic (const Region &other) const
|
||||
{
|
||||
std::auto_ptr<db::DeepRegion> dr_holder;
|
||||
std::unique_ptr<db::DeepRegion> dr_holder;
|
||||
const db::DeepRegion *other_deep = dynamic_cast<const db::DeepRegion *> (other.delegate ());
|
||||
if (! other_deep) {
|
||||
// if the other region isn't deep, turn into a top-level only deep region to facilitate re-hierarchisation
|
||||
|
|
|
|||
|
|
@ -2162,7 +2162,7 @@ EdgeProcessor::process (const std::vector<std::pair<db::EdgeSink *, db::EdgeEval
|
|||
|
||||
size_t todo_max = 1000000;
|
||||
|
||||
std::auto_ptr<tl::AbsoluteProgress> progress (0);
|
||||
std::unique_ptr<tl::AbsoluteProgress> progress;
|
||||
if (m_report_progress) {
|
||||
if (m_progress_desc.empty ()) {
|
||||
progress.reset (new tl::AbsoluteProgress (tl::to_string (tr ("Processing")), 1000));
|
||||
|
|
|
|||
|
|
@ -119,7 +119,7 @@ FlatEdgePairs::filter_in_place (const EdgePairFilterBase &filter)
|
|||
|
||||
EdgePairsDelegate *FlatEdgePairs::add (const EdgePairs &other) const
|
||||
{
|
||||
std::auto_ptr<FlatEdgePairs> new_edge_pairs (new FlatEdgePairs (*this));
|
||||
std::unique_ptr<FlatEdgePairs> new_edge_pairs (new FlatEdgePairs (*this));
|
||||
new_edge_pairs->invalidate_cache ();
|
||||
|
||||
FlatEdgePairs *other_flat = dynamic_cast<FlatEdgePairs *> (other.delegate ());
|
||||
|
|
|
|||
|
|
@ -242,7 +242,7 @@ FlatEdges::filter_in_place (const EdgeFilterBase &filter)
|
|||
|
||||
EdgesDelegate *FlatEdges::add (const Edges &other) const
|
||||
{
|
||||
std::auto_ptr<FlatEdges> new_region (new FlatEdges (*this));
|
||||
std::unique_ptr<FlatEdges> new_region (new FlatEdges (*this));
|
||||
new_region->invalidate_cache ();
|
||||
new_region->set_is_merged (false);
|
||||
|
||||
|
|
|
|||
|
|
@ -327,7 +327,7 @@ RegionDelegate *FlatRegion::merged () const
|
|||
|
||||
RegionDelegate *FlatRegion::add (const Region &other) const
|
||||
{
|
||||
std::auto_ptr<FlatRegion> new_region (new FlatRegion (*this));
|
||||
std::unique_ptr<FlatRegion> new_region (new FlatRegion (*this));
|
||||
new_region->invalidate_cache ();
|
||||
new_region->set_is_merged (false);
|
||||
|
||||
|
|
|
|||
|
|
@ -119,7 +119,7 @@ FlatTexts::filter_in_place (const TextFilterBase &filter)
|
|||
|
||||
TextsDelegate *FlatTexts::add (const Texts &other) const
|
||||
{
|
||||
std::auto_ptr<FlatTexts> new_texts (new FlatTexts (*this));
|
||||
std::unique_ptr<FlatTexts> new_texts (new FlatTexts (*this));
|
||||
new_texts->invalidate_cache ();
|
||||
|
||||
FlatTexts *other_flat = dynamic_cast<FlatTexts *> (other.delegate ());
|
||||
|
|
|
|||
|
|
@ -2304,7 +2304,7 @@ hier_clusters<T>::build_hier_connections (cell_clusters_box_converter<T> &cbc, c
|
|||
|
||||
// NOTE: this is a receiver for both the child-to-child and
|
||||
// local to child interactions.
|
||||
std::auto_ptr<hc_receiver<T> > rec (new hc_receiver<T> (layout, cell, local, *this, cbc, conn, breakout_cells, &instance_interaction_cache));
|
||||
std::unique_ptr<hc_receiver<T> > rec (new hc_receiver<T> (layout, cell, local, *this, cbc, conn, breakout_cells, &instance_interaction_cache));
|
||||
cell_inst_clusters_box_converter<T> cibc (cbc);
|
||||
|
||||
// The box scanner needs pointers so we have to first store the instances
|
||||
|
|
|
|||
|
|
@ -1669,7 +1669,7 @@ local_processor<TS, TI, TR>::compute_results (local_processor_contexts<TS, TI, T
|
|||
|
||||
if (m_nthreads > 0) {
|
||||
|
||||
std::auto_ptr<tl::Job<local_processor_result_computation_worker<TS, TI, TR> > > rc_job (new tl::Job<local_processor_result_computation_worker<TS, TI, TR> > (m_nthreads));
|
||||
std::unique_ptr<tl::Job<local_processor_result_computation_worker<TS, TI, TR> > > rc_job (new tl::Job<local_processor_result_computation_worker<TS, TI, TR> > (m_nthreads));
|
||||
|
||||
// schedule computation jobs in "waves": we need to make sure they are executed
|
||||
// bottom-up. So we identify a new bunch of cells each time we pass through the cell set
|
||||
|
|
|
|||
|
|
@ -494,7 +494,7 @@ private:
|
|||
size_t m_max_vertex_count;
|
||||
double m_area_ratio;
|
||||
int m_base_verbosity;
|
||||
mutable std::auto_ptr<tl::Job<local_processor_context_computation_worker<TS, TI, TR> > > mp_cc_job;
|
||||
mutable std::unique_ptr<tl::Job<local_processor_context_computation_worker<TS, TI, TR> > > mp_cc_job;
|
||||
mutable size_t m_progress;
|
||||
mutable tl::Progress *mp_progress;
|
||||
|
||||
|
|
|
|||
|
|
@ -1379,7 +1379,7 @@ private:
|
|||
NameFilter m_pattern;
|
||||
const db::Cell *mp_parent;
|
||||
db::Layout::top_down_const_iterator m_cell, m_cell_end;
|
||||
std::auto_ptr<db::CellCounter> m_cell_counter;
|
||||
std::unique_ptr<db::CellCounter> m_cell_counter;
|
||||
bool m_reading;
|
||||
db::cell_index_type m_cell_index;
|
||||
};
|
||||
|
|
@ -2222,7 +2222,7 @@ parse_cell_name_filter_element (tl::Extractor &ex, LayoutQuery *q, ChildCellFilt
|
|||
|
||||
} else if (ex.test ("(")) {
|
||||
|
||||
std::auto_ptr<FilterBracket> b (new FilterBracket (q));
|
||||
std::unique_ptr<FilterBracket> b (new FilterBracket (q));
|
||||
do {
|
||||
parse_cell_name_filter_seq (ex, q, b.get (), instance_mode, reading);
|
||||
} while (ex.test (",") || ex.test ("or"));
|
||||
|
|
@ -2276,7 +2276,7 @@ parse_cell_name_filter_element (tl::Extractor &ex, LayoutQuery *q, ChildCellFilt
|
|||
++ex;
|
||||
}
|
||||
|
||||
std::auto_ptr<FilterBracket> b (new ChildCellFilter (q, NameFilterArgument ("*"), instance_mode, reading));
|
||||
std::unique_ptr<FilterBracket> b (new ChildCellFilter (q, NameFilterArgument ("*"), instance_mode, reading));
|
||||
b->set_loopmin (0);
|
||||
b->set_loopmax (std::numeric_limits<unsigned int>::max ());
|
||||
return b.release ();
|
||||
|
|
@ -2360,7 +2360,7 @@ parse_cell_filter (tl::Extractor &ex, LayoutQuery *q, FilterBracket *bracket, bo
|
|||
|
||||
} else {
|
||||
|
||||
std::auto_ptr<FilterBracket> b (new FilterBracket (q));
|
||||
std::unique_ptr<FilterBracket> b (new FilterBracket (q));
|
||||
|
||||
if (ex.test ("instances")) {
|
||||
(ex.test ("of") || ex.test ("from")) && (ex.test ("cells") || ex.test ("cell"));
|
||||
|
|
@ -2437,7 +2437,7 @@ parse_filter (tl::Extractor &ex, LayoutQuery *q, FilterBracket *bracket, bool re
|
|||
|
||||
ex.test ("of") || ex.test ("from");
|
||||
|
||||
std::auto_ptr<FilterBracket> b (new FilterBracket (q));
|
||||
std::unique_ptr<FilterBracket> b (new FilterBracket (q));
|
||||
parse_cell_filter (ex, q, b.get (), false, reading);
|
||||
|
||||
FilterBase *f = 0, *fl = 0;
|
||||
|
|
@ -2482,7 +2482,7 @@ parse_statement (tl::Extractor &ex, LayoutQuery *q, FilterBracket *bracket, bool
|
|||
|
||||
ex.expect ("from");
|
||||
|
||||
std::auto_ptr<FilterBracket> b (new FilterBracket (q));
|
||||
std::unique_ptr<FilterBracket> b (new FilterBracket (q));
|
||||
parse_filter (ex, q, b.get (), true);
|
||||
|
||||
bool unique = false;
|
||||
|
|
@ -2506,7 +2506,7 @@ parse_statement (tl::Extractor &ex, LayoutQuery *q, FilterBracket *bracket, bool
|
|||
|
||||
} else if (! reading && ex.test ("with")) {
|
||||
|
||||
std::auto_ptr<FilterBracket> b (new FilterBracket (q));
|
||||
std::unique_ptr<FilterBracket> b (new FilterBracket (q));
|
||||
parse_filter (ex, q, b.get (), false);
|
||||
|
||||
ex.expect ("do");
|
||||
|
|
@ -2527,7 +2527,7 @@ parse_statement (tl::Extractor &ex, LayoutQuery *q, FilterBracket *bracket, bool
|
|||
|
||||
} else if (! reading && ex.test ("delete")) {
|
||||
|
||||
std::auto_ptr<FilterBracket> b (new FilterBracket (q));
|
||||
std::unique_ptr<FilterBracket> b (new FilterBracket (q));
|
||||
parse_filter (ex, q, b.get (), false);
|
||||
|
||||
bool transparent = ex.test ("pass");
|
||||
|
|
@ -2550,7 +2550,7 @@ parse_statement (tl::Extractor &ex, LayoutQuery *q, FilterBracket *bracket, bool
|
|||
LayoutQuery::LayoutQuery (const std::string &query)
|
||||
: mp_root (0)
|
||||
{
|
||||
std::auto_ptr<FilterBracket> r (new FilterBracket (this));
|
||||
std::unique_ptr<FilterBracket> r (new FilterBracket (this));
|
||||
|
||||
tl::Extractor ex (query.c_str ());
|
||||
parse_statement (ex, this, r.get (), false);
|
||||
|
|
|
|||
|
|
@ -153,7 +153,7 @@ db::Region *LayoutToNetlist::make_layer (const std::string &n)
|
|||
db::RecursiveShapeIterator si (m_iter);
|
||||
si.shape_flags (db::ShapeIterator::Nothing);
|
||||
|
||||
std::auto_ptr <db::Region> region (new db::Region (si, dss ()));
|
||||
std::unique_ptr <db::Region> region (new db::Region (si, dss ()));
|
||||
if (! n.empty ()) {
|
||||
register_layer (*region, n);
|
||||
}
|
||||
|
|
@ -166,7 +166,7 @@ db::Region *LayoutToNetlist::make_layer (unsigned int layer_index, const std::st
|
|||
si.set_layer (layer_index);
|
||||
si.shape_flags (db::ShapeIterator::All);
|
||||
|
||||
std::auto_ptr <db::Region> region (new db::Region (si, dss ()));
|
||||
std::unique_ptr <db::Region> region (new db::Region (si, dss ()));
|
||||
if (! n.empty ()) {
|
||||
register_layer (*region, n);
|
||||
}
|
||||
|
|
@ -179,7 +179,7 @@ db::Texts *LayoutToNetlist::make_text_layer (unsigned int layer_index, const std
|
|||
si.set_layer (layer_index);
|
||||
si.shape_flags (db::ShapeIterator::Texts);
|
||||
|
||||
std::auto_ptr <db::Texts> texts (new db::Texts (si, dss ()));
|
||||
std::unique_ptr <db::Texts> texts (new db::Texts (si, dss ()));
|
||||
if (! n.empty ()) {
|
||||
register_layer (*texts, n);
|
||||
}
|
||||
|
|
@ -192,7 +192,7 @@ db::Region *LayoutToNetlist::make_polygon_layer (unsigned int layer_index, const
|
|||
si.set_layer (layer_index);
|
||||
si.shape_flags (db::ShapeIterator::Paths | db::ShapeIterator::Polygons | db::ShapeIterator::Boxes);
|
||||
|
||||
std::auto_ptr <db::Region> region (new db::Region (si, dss ()));
|
||||
std::unique_ptr <db::Region> region (new db::Region (si, dss ()));
|
||||
if (! n.empty ()) {
|
||||
register_layer (*region, n);
|
||||
}
|
||||
|
|
@ -773,7 +773,7 @@ db::Region *LayoutToNetlist::shapes_of_net (const db::Net &net, const db::Region
|
|||
const db::Circuit *circuit = net.circuit ();
|
||||
tl_assert (circuit != 0);
|
||||
|
||||
std::auto_ptr<db::Region> res (new db::Region ());
|
||||
std::unique_ptr<db::Region> res (new db::Region ());
|
||||
std::map<unsigned int, db::Region *> lmap;
|
||||
lmap [lid] = res.get ();
|
||||
|
||||
|
|
@ -1313,7 +1313,7 @@ void LayoutToNetlist::load (const std::string &path)
|
|||
|
||||
db::LayoutToNetlist *LayoutToNetlist::create_from_file (const std::string &path)
|
||||
{
|
||||
std::auto_ptr<db::LayoutToNetlist> db;
|
||||
std::unique_ptr<db::LayoutToNetlist> db;
|
||||
|
||||
// TODO: generic concept to detect format
|
||||
std::string first_line;
|
||||
|
|
|
|||
|
|
@ -816,12 +816,12 @@ private:
|
|||
std::string m_original_file;
|
||||
std::string m_filename;
|
||||
db::RecursiveShapeIterator m_iter;
|
||||
std::auto_ptr<db::DeepShapeStore> mp_internal_dss;
|
||||
std::unique_ptr<db::DeepShapeStore> mp_internal_dss;
|
||||
tl::weak_ptr<db::DeepShapeStore> mp_dss;
|
||||
unsigned int m_layout_index;
|
||||
db::Connectivity m_conn;
|
||||
db::hier_clusters<db::NetShape> m_net_clusters;
|
||||
std::auto_ptr<db::Netlist> mp_netlist;
|
||||
std::unique_ptr<db::Netlist> mp_netlist;
|
||||
std::set<db::DeepLayer> m_dlrefs;
|
||||
std::map<std::string, db::DeepLayer> m_named_regions;
|
||||
std::map<unsigned int, std::string> m_name_of_layer;
|
||||
|
|
|
|||
|
|
@ -219,7 +219,7 @@ void LayoutToNetlistStandardReader::read_netlist (db::Netlist *netlist, db::Layo
|
|||
read_word_or_quoted (lspec);
|
||||
}
|
||||
|
||||
std::auto_ptr<db::Region> region (l2n->make_layer (layer));
|
||||
std::unique_ptr<db::Region> region (l2n->make_layer (layer));
|
||||
if (! lspec.empty ()) {
|
||||
unsigned int layer_index = l2n->layer_of (*region);
|
||||
tl::Extractor ex (lspec.c_str ());
|
||||
|
|
@ -683,7 +683,7 @@ LayoutToNetlistStandardReader::read_device (db::Netlist *netlist, db::LayoutToNe
|
|||
|
||||
std::pair<db::DeviceAbstract *, const db::DeviceClass *> dm = device_model_by_name (netlist, dmname);
|
||||
|
||||
std::auto_ptr<db::Device> device (new db::Device ());
|
||||
std::unique_ptr<db::Device> device (new db::Device ());
|
||||
device->set_device_class (const_cast<db::DeviceClass *> (dm.second));
|
||||
device->set_device_abstract (dm.first);
|
||||
|
||||
|
|
@ -936,7 +936,7 @@ LayoutToNetlistStandardReader::read_subcircuit (db::Netlist *netlist, db::Layout
|
|||
throw tl::Exception (tl::to_string (tr ("Not a valid device circuit name: ")) + xname);
|
||||
}
|
||||
|
||||
std::auto_ptr<db::SubCircuit> subcircuit (new db::SubCircuit (circuit_ref));
|
||||
std::unique_ptr<db::SubCircuit> subcircuit (new db::SubCircuit (circuit_ref));
|
||||
|
||||
db::DCplxTrans trans;
|
||||
|
||||
|
|
|
|||
|
|
@ -87,7 +87,7 @@ void LayoutVsSchematicStandardReader::read_netlist (db::LayoutVsSchematic *lvs)
|
|||
} else if (test (skeys::reference_key) || test (lkeys::reference_key)) {
|
||||
|
||||
Brace br (this);
|
||||
std::auto_ptr<db::Netlist> netlist (new db::Netlist ());
|
||||
std::unique_ptr<db::Netlist> netlist (new db::Netlist ());
|
||||
LayoutToNetlistStandardReader::read_netlist (netlist.get (), 0, true /*nested*/, &m_map_per_circuit_b);
|
||||
lvs->set_reference_netlist (netlist.release ());
|
||||
br.done ();
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ void local_operation<TS, TI, TR>::compute_local (db::Layout *layout, const shape
|
|||
|
||||
} else {
|
||||
|
||||
std::auto_ptr<tl::RelativeProgress> progress;
|
||||
std::unique_ptr<tl::RelativeProgress> progress;
|
||||
if (report_progress) {
|
||||
progress.reset (new tl::RelativeProgress (progress_desc, interactions.size ()));
|
||||
}
|
||||
|
|
|
|||
|
|
@ -354,9 +354,9 @@ protected:
|
|||
|
||||
mutable NetlistCompareLogger *mp_logger;
|
||||
std::map<std::pair<const db::Circuit *, const db::Circuit *>, std::vector<std::pair<const Net *, const Net *> > > m_same_nets;
|
||||
std::auto_ptr<CircuitPinMapper> mp_circuit_pin_mapper;
|
||||
std::auto_ptr<DeviceCategorizer> mp_device_categorizer;
|
||||
std::auto_ptr<CircuitCategorizer> mp_circuit_categorizer;
|
||||
std::unique_ptr<CircuitPinMapper> mp_circuit_pin_mapper;
|
||||
std::unique_ptr<DeviceCategorizer> mp_device_categorizer;
|
||||
std::unique_ptr<CircuitCategorizer> mp_circuit_categorizer;
|
||||
double m_cap_threshold;
|
||||
double m_res_threshold;
|
||||
size_t m_max_n_branch;
|
||||
|
|
|
|||
|
|
@ -483,7 +483,7 @@ void NetlistDeviceExtractor::extract_devices (const std::vector<db::Region> & /*
|
|||
|
||||
void NetlistDeviceExtractor::register_device_class (DeviceClass *device_class)
|
||||
{
|
||||
std::auto_ptr<DeviceClass> holder (device_class);
|
||||
std::unique_ptr<DeviceClass> holder (device_class);
|
||||
tl_assert (device_class != 0);
|
||||
tl_assert (m_netlist.get () != 0);
|
||||
|
||||
|
|
|
|||
|
|
@ -274,7 +274,7 @@ bool NetlistSpiceReaderDelegate::element (db::Circuit *circuit, const std::strin
|
|||
static const char *allowed_name_chars = "_.:,!+$/&\\#[]|<>";
|
||||
|
||||
NetlistSpiceReader::NetlistSpiceReader (NetlistSpiceReaderDelegate *delegate)
|
||||
: mp_netlist (0), mp_stream (0), mp_delegate (delegate)
|
||||
: mp_netlist (0), mp_stream (), mp_delegate (delegate)
|
||||
{
|
||||
static NetlistSpiceReaderDelegate std_delegate;
|
||||
if (! delegate) {
|
||||
|
|
@ -978,7 +978,7 @@ void NetlistSpiceReader::read_circuit (tl::Extractor &ex, const std::string &nc)
|
|||
}
|
||||
m_circuits_read.insert (cc);
|
||||
|
||||
std::auto_ptr<std::map<std::string, db::Net *> > n2n (mp_nets_by_name.release ());
|
||||
std::unique_ptr<std::map<std::string, db::Net *> > n2n (mp_nets_by_name.release ());
|
||||
mp_nets_by_name.reset (0);
|
||||
|
||||
std::swap (cc, mp_circuit);
|
||||
|
|
|
|||
|
|
@ -125,10 +125,10 @@ private:
|
|||
db::Netlist *mp_netlist;
|
||||
db::Circuit *mp_circuit;
|
||||
db::Circuit *mp_anonymous_top_circuit;
|
||||
std::auto_ptr<tl::TextInputStream> mp_stream;
|
||||
std::unique_ptr<tl::TextInputStream> mp_stream;
|
||||
tl::weak_ptr<NetlistSpiceReaderDelegate> mp_delegate;
|
||||
std::vector<std::pair<tl::InputStream *, tl::TextInputStream *> > m_streams;
|
||||
std::auto_ptr<std::map<std::string, db::Net *> > mp_nets_by_name;
|
||||
std::unique_ptr<std::map<std::string, db::Net *> > mp_nets_by_name;
|
||||
std::string m_stored_line;
|
||||
std::map<std::string, bool> m_captured;
|
||||
std::vector<std::string> m_global_nets;
|
||||
|
|
|
|||
|
|
@ -733,7 +733,7 @@ private:
|
|||
const shapes_type *mp_shapes;
|
||||
|
||||
box_type m_region;
|
||||
std::auto_ptr<region_type> mp_complex_region;
|
||||
std::unique_ptr<region_type> mp_complex_region;
|
||||
db::box_convert<db::CellInst> m_box_convert;
|
||||
|
||||
mutable inst_iterator m_inst;
|
||||
|
|
|
|||
|
|
@ -507,7 +507,7 @@ Region::texts_as_dots (const std::string &pat, bool pattern) const
|
|||
si.first.shape_flags (si.first.shape_flags () & db::ShapeIterator::Texts);
|
||||
}
|
||||
|
||||
std::auto_ptr<db::FlatEdges> res (new db::FlatEdges ());
|
||||
std::unique_ptr<db::FlatEdges> res (new db::FlatEdges ());
|
||||
res->set_merged_semantics (false);
|
||||
|
||||
fill_texts (si.first, pat, pattern, dot_delivery<db::FlatEdges> (), res.get (), si.second, dr);
|
||||
|
|
@ -529,7 +529,7 @@ Region::texts_as_dots (const std::string &pat, bool pattern, db::DeepShapeStore
|
|||
if (! si.first.layout ()) {
|
||||
|
||||
// flat fallback if the source isn't a deep or original layer
|
||||
std::auto_ptr<db::FlatEdges> res (new db::FlatEdges ());
|
||||
std::unique_ptr<db::FlatEdges> res (new db::FlatEdges ());
|
||||
res->set_merged_semantics (false);
|
||||
|
||||
fill_texts (si.first, pat, pattern, dot_delivery<db::FlatEdges> (), res.get (), si.second, dr);
|
||||
|
|
@ -560,7 +560,7 @@ Region::texts_as_boxes (const std::string &pat, bool pattern, db::Coord enl) con
|
|||
si.first.shape_flags (si.first.shape_flags () & db::ShapeIterator::Texts);
|
||||
}
|
||||
|
||||
std::auto_ptr<db::FlatRegion> res (new db::FlatRegion ());
|
||||
std::unique_ptr<db::FlatRegion> res (new db::FlatRegion ());
|
||||
res->set_merged_semantics (false);
|
||||
|
||||
fill_texts (si.first, pat, pattern, box_delivery<db::FlatRegion> (enl), res.get (), si.second, dr);
|
||||
|
|
@ -582,7 +582,7 @@ Region::texts_as_boxes (const std::string &pat, bool pattern, db::Coord enl, db:
|
|||
if (! si.first.layout ()) {
|
||||
|
||||
// flat fallback if the source isn't a deep or original layer
|
||||
std::auto_ptr<db::FlatRegion> res (new db::FlatRegion ());
|
||||
std::unique_ptr<db::FlatRegion> res (new db::FlatRegion ());
|
||||
res->set_merged_semantics (false);
|
||||
|
||||
fill_texts (si.first, pat, pattern, box_delivery<db::FlatRegion> (enl), res.get (), si.second, dr);
|
||||
|
|
|
|||
|
|
@ -169,7 +169,7 @@ DB_PUBLIC_TEMPLATE
|
|||
OutputContainer *
|
||||
shape_collection_processed_impl (const db::DeepLayer &input, const shape_collection_processor<Shape, Result> &filter)
|
||||
{
|
||||
std::auto_ptr<VariantsCollectorBase> vars;
|
||||
std::unique_ptr<VariantsCollectorBase> vars;
|
||||
if (filter.vars ()) {
|
||||
|
||||
vars.reset (new db::VariantsCollectorBase (filter.vars ()));
|
||||
|
|
@ -187,7 +187,7 @@ shape_collection_processed_impl (const db::DeepLayer &input, const shape_collect
|
|||
std::vector<Result> heap;
|
||||
std::map<db::cell_index_type, std::map<db::ICplxTrans, db::Shapes> > to_commit;
|
||||
|
||||
std::auto_ptr<OutputContainer> res (new OutputContainer (input.derived ()));
|
||||
std::unique_ptr<OutputContainer> res (new OutputContainer (input.derived ()));
|
||||
if (filter.result_must_not_be_merged ()) {
|
||||
res->set_merged_semantics (false);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -199,7 +199,7 @@ public:
|
|||
|
||||
void operator () (HOST &options, tl::XMLReaderState &reader) const
|
||||
{
|
||||
std::auto_ptr<OPT> opt (new OPT ());
|
||||
std::unique_ptr<OPT> opt (new OPT ());
|
||||
|
||||
tl::XMLObjTag<OPT> tag;
|
||||
*opt = *reader.back (tag);
|
||||
|
|
|
|||
|
|
@ -67,7 +67,7 @@ Technologies::operator= (const Technologies &other)
|
|||
return *this;
|
||||
}
|
||||
|
||||
static std::auto_ptr<db::Technologies> sp_technologies;
|
||||
static std::unique_ptr<db::Technologies> sp_technologies;
|
||||
|
||||
db::Technologies *
|
||||
Technologies::instance ()
|
||||
|
|
@ -128,7 +128,7 @@ Technologies::add_tech (Technology *tech, bool replace_same)
|
|||
return;
|
||||
}
|
||||
|
||||
std::auto_ptr<Technology> tech_ptr (tech);
|
||||
std::unique_ptr<Technology> tech_ptr (tech);
|
||||
|
||||
Technology *t = 0;
|
||||
for (tl::stable_vector<Technology>::iterator i = m_technologies.begin (); !t && i != m_technologies.end (); ++i) {
|
||||
|
|
|
|||
|
|
@ -44,7 +44,7 @@ struct box_defs
|
|||
static C *from_string (const char *s)
|
||||
{
|
||||
tl::Extractor ex (s);
|
||||
std::auto_ptr<C> c (new C ());
|
||||
std::unique_ptr<C> c (new C ());
|
||||
ex.read (*c.get ());
|
||||
return c.release ();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ struct edge_defs
|
|||
static C *from_string (const char *s)
|
||||
{
|
||||
tl::Extractor ex (s);
|
||||
std::auto_ptr<C> c (new C ());
|
||||
std::unique_ptr<C> c (new C ());
|
||||
ex.read (*c.get ());
|
||||
return c.release ();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -44,7 +44,7 @@ struct edge_pair_defs
|
|||
static C *from_string (const char *s)
|
||||
{
|
||||
tl::Extractor ex (s);
|
||||
std::auto_ptr<C> c (new C ());
|
||||
std::unique_ptr<C> c (new C ());
|
||||
ex.read (*c.get ());
|
||||
return c.release ();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -53,7 +53,7 @@ struct path_defs
|
|||
static C *from_string (const char *s)
|
||||
{
|
||||
tl::Extractor ex (s);
|
||||
std::auto_ptr<C> c (new C ());
|
||||
std::unique_ptr<C> c (new C ());
|
||||
ex.read (*c.get ());
|
||||
return c.release ();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ struct point_defs
|
|||
static C *from_string (const char *s)
|
||||
{
|
||||
tl::Extractor ex (s);
|
||||
std::auto_ptr<C> c (new C ());
|
||||
std::unique_ptr<C> c (new C ());
|
||||
ex.read (*c.get ());
|
||||
return c.release ();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -88,7 +88,7 @@ struct simple_polygon_defs
|
|||
static C *from_string (const char *s)
|
||||
{
|
||||
tl::Extractor ex (s);
|
||||
std::auto_ptr<C> c (new C ());
|
||||
std::unique_ptr<C> c (new C ());
|
||||
ex.read (*c.get ());
|
||||
return c.release ();
|
||||
}
|
||||
|
|
@ -932,7 +932,7 @@ struct polygon_defs
|
|||
static C *from_string (const char *s)
|
||||
{
|
||||
tl::Extractor ex (s);
|
||||
std::auto_ptr<C> c (new C ());
|
||||
std::unique_ptr<C> c (new C ());
|
||||
ex.read (*c.get ());
|
||||
return c.release ();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -612,7 +612,7 @@ static std::vector<db::Region> andnot (const db::Region *r, const db::Region &ot
|
|||
template <class Container>
|
||||
static Container *decompose_convex (const db::Region *r, int mode)
|
||||
{
|
||||
std::auto_ptr<Container> shapes (new Container ());
|
||||
std::unique_ptr<Container> shapes (new Container ());
|
||||
db::SimplePolygonContainer sp;
|
||||
for (db::Region::const_iterator p = r->begin_merged (); ! p.at_end(); ++p) {
|
||||
sp.polygons ().clear ();
|
||||
|
|
@ -627,7 +627,7 @@ static Container *decompose_convex (const db::Region *r, int mode)
|
|||
template <class Container>
|
||||
static Container *decompose_trapezoids (const db::Region *r, int mode)
|
||||
{
|
||||
std::auto_ptr<Container> shapes (new Container ());
|
||||
std::unique_ptr<Container> shapes (new Container ());
|
||||
db::SimplePolygonContainer sp;
|
||||
for (db::Region::const_iterator p = r->begin_merged (); ! p.at_end(); ++p) {
|
||||
sp.polygons ().clear ();
|
||||
|
|
|
|||
|
|
@ -44,7 +44,7 @@ struct text_defs
|
|||
static C *from_string (const char *s)
|
||||
{
|
||||
tl::Extractor ex (s);
|
||||
std::auto_ptr<C> c (new C ());
|
||||
std::unique_ptr<C> c (new C ());
|
||||
ex.read (*c.get ());
|
||||
return c.release ();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -56,7 +56,7 @@ struct trans_defs
|
|||
static C *from_string (const char *s)
|
||||
{
|
||||
tl::Extractor ex (s);
|
||||
std::auto_ptr<C> c (new C ());
|
||||
std::unique_ptr<C> c (new C ());
|
||||
ex.read (*c.get ());
|
||||
return c.release ();
|
||||
}
|
||||
|
|
@ -549,7 +549,7 @@ struct cplx_trans_defs
|
|||
static C *from_string (const char *s)
|
||||
{
|
||||
tl::Extractor ex (s);
|
||||
std::auto_ptr<C> c (new C ());
|
||||
std::unique_ptr<C> c (new C ());
|
||||
ex.read (*c.get ());
|
||||
return c.release ();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ struct vector_defs
|
|||
static C *from_string (const char *s)
|
||||
{
|
||||
tl::Extractor ex (s);
|
||||
std::auto_ptr<C> c (new C ());
|
||||
std::unique_ptr<C> c (new C ());
|
||||
ex.read (*c.get ());
|
||||
return c.release ();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -430,7 +430,7 @@ TEST(5)
|
|||
// Resolution of array references
|
||||
TEST(6)
|
||||
{
|
||||
std::auto_ptr<db::Layout> g (new db::Layout ());
|
||||
std::unique_ptr<db::Layout> g (new db::Layout ());
|
||||
db::Cell &a0 (g->cell (g->add_cell ("a0")));
|
||||
db::Cell *a4p, *a5p;
|
||||
a4p = &(g->cell (g->add_cell ("a4")));
|
||||
|
|
@ -456,7 +456,7 @@ TEST(6)
|
|||
// Multi-mapping
|
||||
TEST(7)
|
||||
{
|
||||
std::auto_ptr<db::Layout> g (new db::Layout ());
|
||||
std::unique_ptr<db::Layout> g (new db::Layout ());
|
||||
db::Cell &a0 (g->cell (g->add_cell ("a0")));
|
||||
db::Cell &a1 (g->cell (g->add_cell ("a1")));
|
||||
db::Cell &a2 (g->cell (g->add_cell ("a2")));
|
||||
|
|
|
|||
|
|
@ -588,7 +588,7 @@ TEST(7_DetachFromOriginalLayout)
|
|||
// using OASIS means we create a lot of references to array
|
||||
// and shape repo - we check here whether these references get
|
||||
// translated or resolved in the hierarchy builder.
|
||||
std::auto_ptr<db::Layout> ly (new db::Layout (false));
|
||||
std::unique_ptr<db::Layout> ly (new db::Layout (false));
|
||||
{
|
||||
std::string fn (tl::testsrc ());
|
||||
fn += "/testdata/algo/hierarchy_builder_l5.oas.gz";
|
||||
|
|
|
|||
|
|
@ -55,7 +55,7 @@ static void dump_nets_to_layout (const db::LayoutToNetlist &l2n, db::Layout &ly,
|
|||
|
||||
for (std::map<const db::Region *, unsigned int>::const_iterator m = lmap.begin (); m != lmap.end (); ++m) {
|
||||
|
||||
std::auto_ptr<db::Region> shapes (l2n.shapes_of_net (*n, *m->first, false));
|
||||
std::unique_ptr<db::Region> shapes (l2n.shapes_of_net (*n, *m->first, false));
|
||||
if (shapes->empty ()) {
|
||||
continue;
|
||||
}
|
||||
|
|
@ -126,7 +126,7 @@ TEST(0_Basic)
|
|||
{
|
||||
db::LayoutToNetlist l2n;
|
||||
|
||||
std::auto_ptr<db::Region> reg (l2n.make_layer ("l1"));
|
||||
std::unique_ptr<db::Region> reg (l2n.make_layer ("l1"));
|
||||
EXPECT_EQ (l2n.is_persisted (*reg), true);
|
||||
EXPECT_EQ (l2n.name (*reg), "l1");
|
||||
EXPECT_EQ (l2n.layer_of (*reg), 0u);
|
||||
|
|
@ -138,7 +138,7 @@ TEST(0_Basic)
|
|||
EXPECT_EQ (l2n.layer_by_index (1) == 0, true);
|
||||
EXPECT_EQ (l2n.layer_by_name ("l2") == 0, true);
|
||||
|
||||
std::auto_ptr<db::Region> reg_copy (l2n.layer_by_name ("l1"));
|
||||
std::unique_ptr<db::Region> reg_copy (l2n.layer_by_name ("l1"));
|
||||
EXPECT_EQ (reg_copy.get () != 0, true);
|
||||
EXPECT_EQ (l2n.name (*reg_copy), "l1");
|
||||
EXPECT_EQ (l2n.layer_of (*reg_copy), 0u);
|
||||
|
|
@ -148,7 +148,7 @@ TEST(0_Basic)
|
|||
EXPECT_EQ (l2n.layer_of (*reg_copy), 0u);
|
||||
reg_copy.reset (0);
|
||||
|
||||
std::auto_ptr<db::Region> reg2 (l2n.make_layer ());
|
||||
std::unique_ptr<db::Region> reg2 (l2n.make_layer ());
|
||||
EXPECT_EQ (l2n.name (1u), "");
|
||||
EXPECT_EQ (l2n.name (*reg2), "");
|
||||
EXPECT_EQ (l2n.layer_of (*reg2), 1u);
|
||||
|
|
@ -156,7 +156,7 @@ TEST(0_Basic)
|
|||
reg2.reset (0);
|
||||
EXPECT_EQ (l2n.internal_layout ()->is_valid_layer (1), false);
|
||||
|
||||
std::auto_ptr<db::Region> reg3 (l2n.make_layer ("l3"));
|
||||
std::unique_ptr<db::Region> reg3 (l2n.make_layer ("l3"));
|
||||
EXPECT_EQ (l2n.name (*reg3), "l3");
|
||||
EXPECT_EQ (l2n.layer_of (*reg3), 1u);
|
||||
|
||||
|
|
@ -202,17 +202,17 @@ TEST(1_BasicExtraction)
|
|||
db::Cell &tc = ly.cell (*ly.begin_top_down ());
|
||||
db::LayoutToNetlist l2n (db::RecursiveShapeIterator (ly, tc, std::set<unsigned int> ()));
|
||||
|
||||
std::auto_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::auto_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::auto_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::auto_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::auto_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::auto_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::auto_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::auto_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::auto_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::auto_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::auto_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
std::unique_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::unique_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::unique_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::unique_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::unique_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::unique_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::unique_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::unique_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::unique_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::unique_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::unique_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
|
||||
// derived regions
|
||||
|
||||
|
|
@ -690,17 +690,17 @@ TEST(2_Probing)
|
|||
db::Cell &tc = ly.cell (*ly.begin_top_down ());
|
||||
db::LayoutToNetlist l2n (db::RecursiveShapeIterator (ly, tc, std::set<unsigned int> ()));
|
||||
|
||||
std::auto_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::auto_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::auto_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::auto_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::auto_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::auto_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::auto_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::auto_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::auto_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::auto_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::auto_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
std::unique_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::unique_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::unique_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::unique_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::unique_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::unique_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::unique_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::unique_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::unique_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::unique_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::unique_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
|
||||
// derived regions
|
||||
|
||||
|
|
@ -942,19 +942,19 @@ TEST(3_GlobalNetConnections)
|
|||
db::Cell &tc = ly.cell (*ly.begin_top_down ());
|
||||
db::LayoutToNetlist l2n (db::RecursiveShapeIterator (ly, tc, std::set<unsigned int> ()));
|
||||
|
||||
std::auto_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::auto_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::auto_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::auto_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::auto_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::auto_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::auto_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::auto_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::auto_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::auto_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::auto_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::auto_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::auto_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
std::unique_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::unique_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::unique_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::unique_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::unique_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::unique_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::unique_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::unique_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::unique_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::unique_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::unique_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::unique_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::unique_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
|
||||
// derived regions
|
||||
|
||||
|
|
@ -1222,20 +1222,20 @@ TEST(4_GlobalNetDeviceExtraction)
|
|||
db::Cell &tc = ly.cell (*ly.begin_top_down ());
|
||||
db::LayoutToNetlist l2n (db::RecursiveShapeIterator (ly, tc, std::set<unsigned int> ()));
|
||||
|
||||
std::auto_ptr<db::Region> rbulk (l2n.make_layer (ly.insert_layer (), "bulk"));
|
||||
std::auto_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::auto_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::auto_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::auto_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::auto_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::auto_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::auto_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::auto_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::auto_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::auto_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::auto_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::auto_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::auto_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
std::unique_ptr<db::Region> rbulk (l2n.make_layer (ly.insert_layer (), "bulk"));
|
||||
std::unique_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::unique_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::unique_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::unique_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::unique_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::unique_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::unique_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::unique_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::unique_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::unique_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::unique_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::unique_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::unique_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
|
||||
// derived regions
|
||||
|
||||
|
|
@ -1508,20 +1508,20 @@ TEST(5_DeviceExtractionWithDeviceCombination)
|
|||
db::Cell &tc = ly.cell (*ly.begin_top_down ());
|
||||
db::LayoutToNetlist l2n (db::RecursiveShapeIterator (ly, tc, std::set<unsigned int> ()));
|
||||
|
||||
std::auto_ptr<db::Region> rbulk (l2n.make_layer ("bulk"));
|
||||
std::auto_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::auto_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::auto_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::auto_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::auto_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::auto_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::auto_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::auto_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::auto_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::auto_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::auto_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::auto_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::auto_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
std::unique_ptr<db::Region> rbulk (l2n.make_layer ("bulk"));
|
||||
std::unique_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::unique_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::unique_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::unique_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::unique_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::unique_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::unique_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::unique_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::unique_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::unique_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::unique_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::unique_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::unique_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
|
||||
// derived regions
|
||||
|
||||
|
|
@ -1786,20 +1786,20 @@ TEST(6_MoreDeviceTypes)
|
|||
db::Cell &tc = ly.cell (*ly.begin_top_down ());
|
||||
db::LayoutToNetlist l2n (db::RecursiveShapeIterator (ly, tc, std::set<unsigned int> ()));
|
||||
|
||||
std::auto_ptr<db::Region> rbulk (l2n.make_layer ("bulk"));
|
||||
std::auto_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::auto_ptr<db::Region> rthickgox (l2n.make_layer (thickgox, "thickgox"));
|
||||
std::auto_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::auto_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::auto_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::auto_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::auto_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::auto_ptr<db::Region> rcont (l2n.make_polygon_layer (cont, "cont"));
|
||||
std::auto_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::auto_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::auto_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::auto_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::auto_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
std::unique_ptr<db::Region> rbulk (l2n.make_layer ("bulk"));
|
||||
std::unique_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::unique_ptr<db::Region> rthickgox (l2n.make_layer (thickgox, "thickgox"));
|
||||
std::unique_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::unique_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::unique_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::unique_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::unique_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::unique_ptr<db::Region> rcont (l2n.make_polygon_layer (cont, "cont"));
|
||||
std::unique_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::unique_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::unique_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::unique_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::unique_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
|
||||
// derived regions
|
||||
|
||||
|
|
@ -1943,20 +1943,20 @@ TEST(7_MoreByEmptyDeviceTypes)
|
|||
db::Cell &tc = ly.cell (*ly.begin_top_down ());
|
||||
db::LayoutToNetlist l2n (db::RecursiveShapeIterator (ly, tc, std::set<unsigned int> ()));
|
||||
|
||||
std::auto_ptr<db::Region> rbulk (l2n.make_layer ("bulk"));
|
||||
std::auto_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::auto_ptr<db::Region> rthickgox (l2n.make_layer (thickgox, "thickgox"));
|
||||
std::auto_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::auto_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::auto_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::auto_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::auto_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::auto_ptr<db::Region> rcont (l2n.make_polygon_layer (cont, "cont"));
|
||||
std::auto_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::auto_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::auto_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::auto_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::auto_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
std::unique_ptr<db::Region> rbulk (l2n.make_layer ("bulk"));
|
||||
std::unique_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::unique_ptr<db::Region> rthickgox (l2n.make_layer (thickgox, "thickgox"));
|
||||
std::unique_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::unique_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::unique_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::unique_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::unique_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::unique_ptr<db::Region> rcont (l2n.make_polygon_layer (cont, "cont"));
|
||||
std::unique_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::unique_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::unique_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::unique_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::unique_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
|
||||
// derived regions
|
||||
|
||||
|
|
@ -2101,20 +2101,20 @@ TEST(8_FlatExtraction)
|
|||
|
||||
db::LayoutToNetlist l2n (ly.cell_name (tc.cell_index ()), ly.dbu ());
|
||||
|
||||
std::auto_ptr<db::Region> rbulk (new db::Region ());
|
||||
std::auto_ptr<db::Region> rnwell (new db::Region (db::RecursiveShapeIterator (ly, tc, nwell)));
|
||||
std::auto_ptr<db::Region> rthickgox (new db::Region (db::RecursiveShapeIterator (ly, tc, thickgox)));
|
||||
std::auto_ptr<db::Region> ractive (new db::Region (db::RecursiveShapeIterator (ly, tc, active)));
|
||||
std::auto_ptr<db::Region> rpplus (new db::Region (db::RecursiveShapeIterator (ly, tc, pplus)));
|
||||
std::auto_ptr<db::Region> rnplus (new db::Region (db::RecursiveShapeIterator (ly, tc, nplus)));
|
||||
std::auto_ptr<db::Region> rpoly (new db::Region (db::RecursiveShapeIterator (ly, tc, poly)));
|
||||
std::auto_ptr<db::Region> rpoly_lbl (new db::Region (db::RecursiveShapeIterator (ly, tc, poly_lbl)));
|
||||
std::auto_ptr<db::Region> rcont (new db::Region (db::RecursiveShapeIterator (ly, tc, cont)));
|
||||
std::auto_ptr<db::Region> rmetal1 (new db::Region (db::RecursiveShapeIterator (ly, tc, metal1)));
|
||||
std::auto_ptr<db::Region> rmetal1_lbl (new db::Region (db::RecursiveShapeIterator (ly, tc, metal1_lbl)));
|
||||
std::auto_ptr<db::Region> rvia1 (new db::Region (db::RecursiveShapeIterator (ly, tc, via1)));
|
||||
std::auto_ptr<db::Region> rmetal2 (new db::Region (db::RecursiveShapeIterator (ly, tc, metal2)));
|
||||
std::auto_ptr<db::Region> rmetal2_lbl (new db::Region (db::RecursiveShapeIterator (ly, tc, metal2_lbl)));
|
||||
std::unique_ptr<db::Region> rbulk (new db::Region ());
|
||||
std::unique_ptr<db::Region> rnwell (new db::Region (db::RecursiveShapeIterator (ly, tc, nwell)));
|
||||
std::unique_ptr<db::Region> rthickgox (new db::Region (db::RecursiveShapeIterator (ly, tc, thickgox)));
|
||||
std::unique_ptr<db::Region> ractive (new db::Region (db::RecursiveShapeIterator (ly, tc, active)));
|
||||
std::unique_ptr<db::Region> rpplus (new db::Region (db::RecursiveShapeIterator (ly, tc, pplus)));
|
||||
std::unique_ptr<db::Region> rnplus (new db::Region (db::RecursiveShapeIterator (ly, tc, nplus)));
|
||||
std::unique_ptr<db::Region> rpoly (new db::Region (db::RecursiveShapeIterator (ly, tc, poly)));
|
||||
std::unique_ptr<db::Region> rpoly_lbl (new db::Region (db::RecursiveShapeIterator (ly, tc, poly_lbl)));
|
||||
std::unique_ptr<db::Region> rcont (new db::Region (db::RecursiveShapeIterator (ly, tc, cont)));
|
||||
std::unique_ptr<db::Region> rmetal1 (new db::Region (db::RecursiveShapeIterator (ly, tc, metal1)));
|
||||
std::unique_ptr<db::Region> rmetal1_lbl (new db::Region (db::RecursiveShapeIterator (ly, tc, metal1_lbl)));
|
||||
std::unique_ptr<db::Region> rvia1 (new db::Region (db::RecursiveShapeIterator (ly, tc, via1)));
|
||||
std::unique_ptr<db::Region> rmetal2 (new db::Region (db::RecursiveShapeIterator (ly, tc, metal2)));
|
||||
std::unique_ptr<db::Region> rmetal2_lbl (new db::Region (db::RecursiveShapeIterator (ly, tc, metal2_lbl)));
|
||||
|
||||
l2n.register_layer (*rbulk, "bulk");
|
||||
l2n.register_layer (*rnwell, "nwell");
|
||||
|
|
@ -2285,20 +2285,20 @@ TEST(9_FlatExtractionWithExternalDSS)
|
|||
|
||||
db::LayoutToNetlist l2n (&dss);
|
||||
|
||||
std::auto_ptr<db::Region> rbulk (new db::Region ());
|
||||
std::auto_ptr<db::Region> rnwell (new db::Region (db::RecursiveShapeIterator (ly, tc, nwell), dss));
|
||||
std::auto_ptr<db::Region> rthickgox (new db::Region (db::RecursiveShapeIterator (ly, tc, thickgox), dss));
|
||||
std::auto_ptr<db::Region> ractive (new db::Region (db::RecursiveShapeIterator (ly, tc, active), dss));
|
||||
std::auto_ptr<db::Region> rpplus (new db::Region (db::RecursiveShapeIterator (ly, tc, pplus), dss));
|
||||
std::auto_ptr<db::Region> rnplus (new db::Region (db::RecursiveShapeIterator (ly, tc, nplus), dss));
|
||||
std::auto_ptr<db::Region> rpoly (new db::Region (db::RecursiveShapeIterator (ly, tc, poly), dss));
|
||||
std::auto_ptr<db::Region> rpoly_lbl (new db::Region (db::RecursiveShapeIterator (ly, tc, poly_lbl), dss));
|
||||
std::auto_ptr<db::Region> rcont (new db::Region (db::RecursiveShapeIterator (ly, tc, cont), dss));
|
||||
std::auto_ptr<db::Region> rmetal1 (new db::Region (db::RecursiveShapeIterator (ly, tc, metal1), dss));
|
||||
std::auto_ptr<db::Region> rmetal1_lbl (new db::Region (db::RecursiveShapeIterator (ly, tc, metal1_lbl), dss));
|
||||
std::auto_ptr<db::Region> rvia1 (new db::Region (db::RecursiveShapeIterator (ly, tc, via1), dss));
|
||||
std::auto_ptr<db::Region> rmetal2 (new db::Region (db::RecursiveShapeIterator (ly, tc, metal2), dss));
|
||||
std::auto_ptr<db::Region> rmetal2_lbl (new db::Region (db::RecursiveShapeIterator (ly, tc, metal2_lbl), dss));
|
||||
std::unique_ptr<db::Region> rbulk (new db::Region ());
|
||||
std::unique_ptr<db::Region> rnwell (new db::Region (db::RecursiveShapeIterator (ly, tc, nwell), dss));
|
||||
std::unique_ptr<db::Region> rthickgox (new db::Region (db::RecursiveShapeIterator (ly, tc, thickgox), dss));
|
||||
std::unique_ptr<db::Region> ractive (new db::Region (db::RecursiveShapeIterator (ly, tc, active), dss));
|
||||
std::unique_ptr<db::Region> rpplus (new db::Region (db::RecursiveShapeIterator (ly, tc, pplus), dss));
|
||||
std::unique_ptr<db::Region> rnplus (new db::Region (db::RecursiveShapeIterator (ly, tc, nplus), dss));
|
||||
std::unique_ptr<db::Region> rpoly (new db::Region (db::RecursiveShapeIterator (ly, tc, poly), dss));
|
||||
std::unique_ptr<db::Region> rpoly_lbl (new db::Region (db::RecursiveShapeIterator (ly, tc, poly_lbl), dss));
|
||||
std::unique_ptr<db::Region> rcont (new db::Region (db::RecursiveShapeIterator (ly, tc, cont), dss));
|
||||
std::unique_ptr<db::Region> rmetal1 (new db::Region (db::RecursiveShapeIterator (ly, tc, metal1), dss));
|
||||
std::unique_ptr<db::Region> rmetal1_lbl (new db::Region (db::RecursiveShapeIterator (ly, tc, metal1_lbl), dss));
|
||||
std::unique_ptr<db::Region> rvia1 (new db::Region (db::RecursiveShapeIterator (ly, tc, via1), dss));
|
||||
std::unique_ptr<db::Region> rmetal2 (new db::Region (db::RecursiveShapeIterator (ly, tc, metal2), dss));
|
||||
std::unique_ptr<db::Region> rmetal2_lbl (new db::Region (db::RecursiveShapeIterator (ly, tc, metal2_lbl), dss));
|
||||
|
||||
l2n.register_layer (*rbulk, "bulk");
|
||||
l2n.register_layer (*rnwell, "nwell");
|
||||
|
|
@ -2457,12 +2457,12 @@ TEST(10_Antenna)
|
|||
|
||||
db::DeepShapeStore dss;
|
||||
|
||||
std::auto_ptr<db::Region> rdiode (new db::Region (db::RecursiveShapeIterator (ly, tc, diode), dss));
|
||||
std::auto_ptr<db::Region> rpoly (new db::Region (db::RecursiveShapeIterator (ly, tc, poly), dss));
|
||||
std::auto_ptr<db::Region> rcont (new db::Region (db::RecursiveShapeIterator (ly, tc, cont), dss));
|
||||
std::auto_ptr<db::Region> rmetal1 (new db::Region (db::RecursiveShapeIterator (ly, tc, metal1), dss));
|
||||
std::auto_ptr<db::Region> rvia1 (new db::Region (db::RecursiveShapeIterator (ly, tc, via1), dss));
|
||||
std::auto_ptr<db::Region> rmetal2 (new db::Region (db::RecursiveShapeIterator (ly, tc, metal2), dss));
|
||||
std::unique_ptr<db::Region> rdiode (new db::Region (db::RecursiveShapeIterator (ly, tc, diode), dss));
|
||||
std::unique_ptr<db::Region> rpoly (new db::Region (db::RecursiveShapeIterator (ly, tc, poly), dss));
|
||||
std::unique_ptr<db::Region> rcont (new db::Region (db::RecursiveShapeIterator (ly, tc, cont), dss));
|
||||
std::unique_ptr<db::Region> rmetal1 (new db::Region (db::RecursiveShapeIterator (ly, tc, metal1), dss));
|
||||
std::unique_ptr<db::Region> rvia1 (new db::Region (db::RecursiveShapeIterator (ly, tc, via1), dss));
|
||||
std::unique_ptr<db::Region> rmetal2 (new db::Region (db::RecursiveShapeIterator (ly, tc, metal2), dss));
|
||||
|
||||
db::Layout ly2;
|
||||
ly2.dbu (ly.dbu ());
|
||||
|
|
@ -2734,17 +2734,17 @@ TEST(11_DuplicateInstances)
|
|||
db::Cell &tc = ly.cell (*ly.begin_top_down ());
|
||||
db::LayoutToNetlist l2n (db::RecursiveShapeIterator (ly, tc, std::set<unsigned int> ()));
|
||||
|
||||
std::auto_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::auto_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::auto_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::auto_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::auto_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::auto_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::auto_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::auto_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::auto_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::auto_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::auto_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
std::unique_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::unique_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::unique_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::unique_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::unique_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::unique_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::unique_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::unique_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::unique_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::unique_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::unique_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
|
||||
// derived regions
|
||||
|
||||
|
|
@ -2939,20 +2939,20 @@ TEST(12_FlattenCircuitDoesFlattenLayout)
|
|||
db::Cell &tc = ly.cell (*ly.begin_top_down ());
|
||||
db::LayoutToNetlist l2n (db::RecursiveShapeIterator (ly, tc, std::set<unsigned int> ()));
|
||||
|
||||
std::auto_ptr<db::Region> rbulk (l2n.make_layer ("bulk"));
|
||||
std::auto_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::auto_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::auto_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::auto_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::auto_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::auto_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::auto_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::auto_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::auto_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::auto_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::auto_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::auto_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::auto_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
std::unique_ptr<db::Region> rbulk (l2n.make_layer ("bulk"));
|
||||
std::unique_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::unique_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::unique_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::unique_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::unique_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::unique_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::unique_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::unique_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::unique_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::unique_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::unique_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::unique_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::unique_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
|
||||
// derived regions
|
||||
|
||||
|
|
@ -3193,20 +3193,20 @@ TEST(13_JoinNets)
|
|||
db::Cell &tc = ly.cell (*ly.begin_top_down ());
|
||||
db::LayoutToNetlist l2n (db::RecursiveShapeIterator (ly, tc, std::set<unsigned int> ()));
|
||||
|
||||
std::auto_ptr<db::Region> rbulk (l2n.make_layer ("bulk"));
|
||||
std::auto_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::auto_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::auto_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::auto_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::auto_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::auto_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::auto_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::auto_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::auto_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::auto_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::auto_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::auto_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::auto_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
std::unique_ptr<db::Region> rbulk (l2n.make_layer ("bulk"));
|
||||
std::unique_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::unique_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::unique_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::unique_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::unique_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::unique_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::unique_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::unique_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::unique_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::unique_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::unique_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::unique_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::unique_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
|
||||
// derived regions
|
||||
|
||||
|
|
|
|||
|
|
@ -73,17 +73,17 @@ TEST(1_WriterBasic)
|
|||
db::Cell &tc = ly.cell (*ly.begin_top_down ());
|
||||
db::LayoutToNetlist l2n (db::RecursiveShapeIterator (ly, tc, std::set<unsigned int> ()));
|
||||
|
||||
std::auto_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::auto_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::auto_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::auto_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::auto_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::auto_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::auto_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::auto_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::auto_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::auto_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::auto_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
std::unique_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::unique_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::unique_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::unique_ptr<db::Texts> rpoly_lbl (l2n.make_text_layer (poly_lbl, "poly_lbl"));
|
||||
std::unique_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::unique_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::unique_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::unique_ptr<db::Texts> rmetal1_lbl (l2n.make_text_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::unique_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::unique_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::unique_ptr<db::Texts> rmetal2_lbl (l2n.make_text_layer (metal2_lbl, "metal2_lbl"));
|
||||
|
||||
// derived regions
|
||||
|
||||
|
|
@ -283,20 +283,20 @@ TEST(2_WriterWithGlobalNets)
|
|||
db::Cell &tc = ly.cell (*ly.begin_top_down ());
|
||||
db::LayoutToNetlist l2n (db::RecursiveShapeIterator (ly, tc, std::set<unsigned int> ()));
|
||||
|
||||
std::auto_ptr<db::Region> rbulk (l2n.make_layer (ly.insert_layer (), "rbulk"));
|
||||
std::auto_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::auto_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::auto_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::auto_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::auto_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::auto_ptr<db::Region> rpoly_lbl (l2n.make_layer (poly_lbl, "poly_lbl"));
|
||||
std::auto_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::auto_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::auto_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::auto_ptr<db::Region> rmetal1_lbl (l2n.make_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::auto_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::auto_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::auto_ptr<db::Region> rmetal2_lbl (l2n.make_layer (metal2_lbl, "metal2_lbl"));
|
||||
std::unique_ptr<db::Region> rbulk (l2n.make_layer (ly.insert_layer (), "rbulk"));
|
||||
std::unique_ptr<db::Region> rnwell (l2n.make_layer (nwell, "nwell"));
|
||||
std::unique_ptr<db::Region> ractive (l2n.make_layer (active, "active"));
|
||||
std::unique_ptr<db::Region> rpplus (l2n.make_layer (pplus, "pplus"));
|
||||
std::unique_ptr<db::Region> rnplus (l2n.make_layer (nplus, "nplus"));
|
||||
std::unique_ptr<db::Region> rpoly (l2n.make_polygon_layer (poly, "poly"));
|
||||
std::unique_ptr<db::Region> rpoly_lbl (l2n.make_layer (poly_lbl, "poly_lbl"));
|
||||
std::unique_ptr<db::Region> rdiff_cont (l2n.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::unique_ptr<db::Region> rpoly_cont (l2n.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::unique_ptr<db::Region> rmetal1 (l2n.make_polygon_layer (metal1, "metal1"));
|
||||
std::unique_ptr<db::Region> rmetal1_lbl (l2n.make_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::unique_ptr<db::Region> rvia1 (l2n.make_polygon_layer (via1, "via1"));
|
||||
std::unique_ptr<db::Region> rmetal2 (l2n.make_polygon_layer (metal2, "metal2"));
|
||||
std::unique_ptr<db::Region> rmetal2_lbl (l2n.make_layer (metal2_lbl, "metal2_lbl"));
|
||||
|
||||
// derived regions
|
||||
|
||||
|
|
|
|||
|
|
@ -89,20 +89,20 @@ TEST(1_BasicFlow)
|
|||
db::Cell &tc = ly.cell (*ly.begin_top_down ());
|
||||
db::LayoutVsSchematic lvs (db::RecursiveShapeIterator (ly, tc, std::set<unsigned int> ()));
|
||||
|
||||
std::auto_ptr<db::Region> rbulk (lvs.make_layer ("bulk"));
|
||||
std::auto_ptr<db::Region> rnwell (lvs.make_layer (nwell, "nwell"));
|
||||
std::auto_ptr<db::Region> ractive (lvs.make_layer (active, "active"));
|
||||
std::auto_ptr<db::Region> rpplus (lvs.make_layer (pplus, "pplus"));
|
||||
std::auto_ptr<db::Region> rnplus (lvs.make_layer (nplus, "nplus"));
|
||||
std::auto_ptr<db::Region> rpoly (lvs.make_polygon_layer (poly, "poly"));
|
||||
std::auto_ptr<db::Region> rpoly_lbl (lvs.make_layer (poly_lbl, "poly_lbl"));
|
||||
std::auto_ptr<db::Region> rdiff_cont (lvs.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::auto_ptr<db::Region> rpoly_cont (lvs.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::auto_ptr<db::Region> rmetal1 (lvs.make_polygon_layer (metal1, "metal1"));
|
||||
std::auto_ptr<db::Region> rmetal1_lbl (lvs.make_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::auto_ptr<db::Region> rvia1 (lvs.make_polygon_layer (via1, "via1"));
|
||||
std::auto_ptr<db::Region> rmetal2 (lvs.make_polygon_layer (metal2, "metal2"));
|
||||
std::auto_ptr<db::Region> rmetal2_lbl (lvs.make_layer (metal2_lbl, "metal2_lbl"));
|
||||
std::unique_ptr<db::Region> rbulk (lvs.make_layer ("bulk"));
|
||||
std::unique_ptr<db::Region> rnwell (lvs.make_layer (nwell, "nwell"));
|
||||
std::unique_ptr<db::Region> ractive (lvs.make_layer (active, "active"));
|
||||
std::unique_ptr<db::Region> rpplus (lvs.make_layer (pplus, "pplus"));
|
||||
std::unique_ptr<db::Region> rnplus (lvs.make_layer (nplus, "nplus"));
|
||||
std::unique_ptr<db::Region> rpoly (lvs.make_polygon_layer (poly, "poly"));
|
||||
std::unique_ptr<db::Region> rpoly_lbl (lvs.make_layer (poly_lbl, "poly_lbl"));
|
||||
std::unique_ptr<db::Region> rdiff_cont (lvs.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::unique_ptr<db::Region> rpoly_cont (lvs.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::unique_ptr<db::Region> rmetal1 (lvs.make_polygon_layer (metal1, "metal1"));
|
||||
std::unique_ptr<db::Region> rmetal1_lbl (lvs.make_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::unique_ptr<db::Region> rvia1 (lvs.make_polygon_layer (via1, "via1"));
|
||||
std::unique_ptr<db::Region> rmetal2 (lvs.make_polygon_layer (metal2, "metal2"));
|
||||
std::unique_ptr<db::Region> rmetal2_lbl (lvs.make_layer (metal2_lbl, "metal2_lbl"));
|
||||
|
||||
// derived regions
|
||||
|
||||
|
|
@ -215,7 +215,7 @@ TEST(1_BasicFlow)
|
|||
fn = tl::combine_path (fn, "algo");
|
||||
fn = tl::combine_path (fn, "lvs_test_1.spi");
|
||||
|
||||
std::auto_ptr<db::Netlist> netlist (new db::Netlist ());
|
||||
std::unique_ptr<db::Netlist> netlist (new db::Netlist ());
|
||||
tl::InputStream stream (fn);
|
||||
reader.read (stream, *netlist);
|
||||
lvs.set_reference_netlist (netlist.release ());
|
||||
|
|
@ -287,20 +287,20 @@ TEST(2_FlowWithErrors)
|
|||
db::Cell &tc = ly.cell (*ly.begin_top_down ());
|
||||
db::LayoutVsSchematic lvs (db::RecursiveShapeIterator (ly, tc, std::set<unsigned int> ()));
|
||||
|
||||
std::auto_ptr<db::Region> rbulk (lvs.make_layer ("bulk"));
|
||||
std::auto_ptr<db::Region> rnwell (lvs.make_layer (nwell, "nwell"));
|
||||
std::auto_ptr<db::Region> ractive (lvs.make_layer (active, "active"));
|
||||
std::auto_ptr<db::Region> rpplus (lvs.make_layer (pplus, "pplus"));
|
||||
std::auto_ptr<db::Region> rnplus (lvs.make_layer (nplus, "nplus"));
|
||||
std::auto_ptr<db::Region> rpoly (lvs.make_polygon_layer (poly, "poly"));
|
||||
std::auto_ptr<db::Region> rpoly_lbl (lvs.make_layer (poly_lbl, "poly_lbl"));
|
||||
std::auto_ptr<db::Region> rdiff_cont (lvs.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::auto_ptr<db::Region> rpoly_cont (lvs.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::auto_ptr<db::Region> rmetal1 (lvs.make_polygon_layer (metal1, "metal1"));
|
||||
std::auto_ptr<db::Region> rmetal1_lbl (lvs.make_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::auto_ptr<db::Region> rvia1 (lvs.make_polygon_layer (via1, "via1"));
|
||||
std::auto_ptr<db::Region> rmetal2 (lvs.make_polygon_layer (metal2, "metal2"));
|
||||
std::auto_ptr<db::Region> rmetal2_lbl (lvs.make_layer (metal2_lbl, "metal2_lbl"));
|
||||
std::unique_ptr<db::Region> rbulk (lvs.make_layer ("bulk"));
|
||||
std::unique_ptr<db::Region> rnwell (lvs.make_layer (nwell, "nwell"));
|
||||
std::unique_ptr<db::Region> ractive (lvs.make_layer (active, "active"));
|
||||
std::unique_ptr<db::Region> rpplus (lvs.make_layer (pplus, "pplus"));
|
||||
std::unique_ptr<db::Region> rnplus (lvs.make_layer (nplus, "nplus"));
|
||||
std::unique_ptr<db::Region> rpoly (lvs.make_polygon_layer (poly, "poly"));
|
||||
std::unique_ptr<db::Region> rpoly_lbl (lvs.make_layer (poly_lbl, "poly_lbl"));
|
||||
std::unique_ptr<db::Region> rdiff_cont (lvs.make_polygon_layer (diff_cont, "diff_cont"));
|
||||
std::unique_ptr<db::Region> rpoly_cont (lvs.make_polygon_layer (poly_cont, "poly_cont"));
|
||||
std::unique_ptr<db::Region> rmetal1 (lvs.make_polygon_layer (metal1, "metal1"));
|
||||
std::unique_ptr<db::Region> rmetal1_lbl (lvs.make_layer (metal1_lbl, "metal1_lbl"));
|
||||
std::unique_ptr<db::Region> rvia1 (lvs.make_polygon_layer (via1, "via1"));
|
||||
std::unique_ptr<db::Region> rmetal2 (lvs.make_polygon_layer (metal2, "metal2"));
|
||||
std::unique_ptr<db::Region> rmetal2_lbl (lvs.make_layer (metal2_lbl, "metal2_lbl"));
|
||||
|
||||
// derived regions
|
||||
|
||||
|
|
@ -413,7 +413,7 @@ TEST(2_FlowWithErrors)
|
|||
fn = tl::combine_path (fn, "algo");
|
||||
fn = tl::combine_path (fn, "lvs_test_2.spi");
|
||||
|
||||
std::auto_ptr<db::Netlist> netlist (new db::Netlist ());
|
||||
std::unique_ptr<db::Netlist> netlist (new db::Netlist ());
|
||||
tl::InputStream stream (fn);
|
||||
reader.read (stream, *netlist);
|
||||
lvs.set_reference_netlist (netlist.release ());
|
||||
|
|
|
|||
|
|
@ -390,7 +390,7 @@ TEST(4_CircuitDevices)
|
|||
dc2.add_parameter_definition (db::DeviceParameterDefinition ("U", "", 2.0));
|
||||
dc2.add_parameter_definition (db::DeviceParameterDefinition ("V", "", 1.0));
|
||||
|
||||
std::auto_ptr<db::Circuit> c (new db::Circuit ());
|
||||
std::unique_ptr<db::Circuit> c (new db::Circuit ());
|
||||
c->set_name ("c");
|
||||
|
||||
EXPECT_EQ (netlist2 (*c),
|
||||
|
|
@ -535,7 +535,7 @@ TEST(4_CircuitDevices)
|
|||
|
||||
TEST(4_NetlistSubcircuits)
|
||||
{
|
||||
std::auto_ptr<db::Netlist> nl (new db::Netlist ());
|
||||
std::unique_ptr<db::Netlist> nl (new db::Netlist ());
|
||||
|
||||
db::DeviceClass *dc = new db::DeviceClass ();
|
||||
dc->set_name ("dc2");
|
||||
|
|
@ -543,7 +543,7 @@ TEST(4_NetlistSubcircuits)
|
|||
dc->add_terminal_definition (db::DeviceTerminalDefinition ("B", ""));
|
||||
nl->add_device_class (dc);
|
||||
|
||||
std::auto_ptr<db::Netlist> nldup (new db::Netlist ());
|
||||
std::unique_ptr<db::Netlist> nldup (new db::Netlist ());
|
||||
nldup->add_device_class (dc->clone ());
|
||||
|
||||
db::DeviceAbstract *dm = new db::DeviceAbstract ();
|
||||
|
|
@ -1001,7 +1001,7 @@ TEST(10_NetPinRefBasics)
|
|||
|
||||
TEST(11_NetlistCircuitRefs)
|
||||
{
|
||||
std::auto_ptr<db::Netlist> nl (new db::Netlist ());
|
||||
std::unique_ptr<db::Netlist> nl (new db::Netlist ());
|
||||
|
||||
db::Circuit *c1 = new db::Circuit ();
|
||||
c1->set_name ("c1");
|
||||
|
|
@ -1036,7 +1036,7 @@ TEST(11_NetlistCircuitRefs)
|
|||
|
||||
TEST(12_NetlistTopology)
|
||||
{
|
||||
std::auto_ptr<db::Netlist> nl (new db::Netlist ());
|
||||
std::unique_ptr<db::Netlist> nl (new db::Netlist ());
|
||||
EXPECT_EQ (nl->top_circuit_count (), size_t (0));
|
||||
|
||||
db::Circuit *c1 = new db::Circuit ();
|
||||
|
|
@ -1053,7 +1053,7 @@ TEST(12_NetlistTopology)
|
|||
EXPECT_EQ (td2string (nl.get ()), "c2,c1");
|
||||
EXPECT_EQ (bu2string (nl.get ()), "c1,c2");
|
||||
|
||||
std::auto_ptr<db::NetlistLocker> locker (new db::NetlistLocker (nl.get ()));
|
||||
std::unique_ptr<db::NetlistLocker> locker (new db::NetlistLocker (nl.get ()));
|
||||
|
||||
db::Circuit *c3 = new db::Circuit ();
|
||||
c3->set_name ("c3");
|
||||
|
|
|
|||
|
|
@ -379,7 +379,7 @@ InstPropertiesPage::create_applicator (db::Cell & /*cell*/, const db::Instance &
|
|||
bool has_error = false;
|
||||
bool has_pcell_error = false;
|
||||
|
||||
std::auto_ptr<CombinedChangeApplicator> appl (new CombinedChangeApplicator ());
|
||||
std::unique_ptr<CombinedChangeApplicator> appl (new CombinedChangeApplicator ());
|
||||
|
||||
edt::Service::obj_iterator pos = m_selection_ptrs [m_index];
|
||||
const lay::CellView &cv = mp_service->view ()->cellview (pos->cv_index ());
|
||||
|
|
@ -608,7 +608,7 @@ InstPropertiesPage::do_apply (bool current_only, bool relative)
|
|||
lay::LayerState layer_state = mp_service->view ()->layer_snapshot ();
|
||||
unsigned int cv_index = m_selection_ptrs [m_index]->cv_index ();
|
||||
|
||||
std::auto_ptr<ChangeApplicator> applicator;
|
||||
std::unique_ptr<ChangeApplicator> applicator;
|
||||
|
||||
{
|
||||
edt::Service::obj_iterator pos = m_selection_ptrs [m_index];
|
||||
|
|
|
|||
|
|
@ -2107,7 +2107,7 @@ MainService::cm_tap ()
|
|||
|
||||
// List the layers under the cursor as pop up a menu
|
||||
|
||||
std::auto_ptr<QMenu> menu (new QMenu (view ()));
|
||||
std::unique_ptr<QMenu> menu (new QMenu (view ()));
|
||||
menu->show ();
|
||||
|
||||
int icon_size = menu->style ()->pixelMetric (QStyle::PM_ButtonIconSize);
|
||||
|
|
|
|||
|
|
@ -178,7 +178,7 @@ ShapePropertiesPage::recompute_selection_ptrs (const std::vector<lay::ObjectInst
|
|||
void
|
||||
ShapePropertiesPage::do_apply (bool current_only, bool relative)
|
||||
{
|
||||
std::auto_ptr<ChangeApplicator> applicator;
|
||||
std::unique_ptr<ChangeApplicator> applicator;
|
||||
|
||||
unsigned int cv_index = m_selection_ptrs [m_index]->cv_index ();
|
||||
|
||||
|
|
@ -856,7 +856,7 @@ TextPropertiesPage::create_applicator (db::Shapes & /*shapes*/, const db::Shape
|
|||
db::Text org_text;
|
||||
shape.text (org_text);
|
||||
|
||||
std::auto_ptr<CombinedChangeApplicator> appl (new CombinedChangeApplicator ());
|
||||
std::unique_ptr<CombinedChangeApplicator> appl (new CombinedChangeApplicator ());
|
||||
|
||||
if (db::FTrans (tt) != db::FTrans (org_text.trans ())) {
|
||||
appl->add (new TextOrientationChangeApplicator (db::FTrans (tt)));
|
||||
|
|
@ -1126,7 +1126,7 @@ EditablePathPropertiesPage::create_applicator (db::Shapes & /*shapes*/, const db
|
|||
break;
|
||||
}
|
||||
|
||||
std::auto_ptr<CombinedChangeApplicator> appl (new CombinedChangeApplicator ());
|
||||
std::unique_ptr<CombinedChangeApplicator> appl (new CombinedChangeApplicator ());
|
||||
|
||||
db::Path org_path;
|
||||
shape.path (org_path);
|
||||
|
|
|
|||
|
|
@ -899,7 +899,7 @@ private:
|
|||
gsi::VariantUserClass<X> m_var_cls;
|
||||
gsi::VariantUserClass<X> m_var_cls_c;
|
||||
gsi::VariantUserClass<X> m_var_cls_cls;
|
||||
std::auto_ptr<SubClassTesterBase> m_subclass_tester;
|
||||
std::unique_ptr<SubClassTesterBase> m_subclass_tester;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -631,7 +631,7 @@ private:
|
|||
std::string m_name;
|
||||
std::string m_module;
|
||||
tl::weak_collection<ClassBase> m_child_classes, m_subclasses;
|
||||
mutable std::auto_ptr<PerClassClientSpecificData> mp_data[ClientIndex::MaxClientIndex];
|
||||
mutable std::unique_ptr<PerClassClientSpecificData> mp_data[ClientIndex::MaxClientIndex];
|
||||
|
||||
static class_collection *mp_class_collection;
|
||||
static class_collection *mp_new_class_collection;
|
||||
|
|
|
|||
|
|
@ -444,7 +444,7 @@ public:
|
|||
{
|
||||
mp_expr.reset (0);
|
||||
|
||||
std::auto_ptr<tl::Expression> ex (new tl::Expression ());
|
||||
std::unique_ptr<tl::Expression> ex (new tl::Expression ());
|
||||
tl::Eval::parse (*ex, e);
|
||||
mp_expr.reset (ex.release ());
|
||||
}
|
||||
|
|
@ -459,7 +459,7 @@ public:
|
|||
}
|
||||
|
||||
private:
|
||||
std::auto_ptr<tl::Expression> mp_expr;
|
||||
std::unique_ptr<tl::Expression> mp_expr;
|
||||
};
|
||||
|
||||
static tl::Variant eval_expr (const std::string &e)
|
||||
|
|
@ -471,14 +471,14 @@ static tl::Variant eval_expr (const std::string &e)
|
|||
|
||||
static ExpressionWrapper *new_expr1 (const std::string &e)
|
||||
{
|
||||
std::auto_ptr<ExpressionWrapper> expr (new ExpressionWrapper ());
|
||||
std::unique_ptr<ExpressionWrapper> expr (new ExpressionWrapper ());
|
||||
expr->parse (e);
|
||||
return expr.release ();
|
||||
}
|
||||
|
||||
static ExpressionWrapper *new_expr2 (const std::string &e, const std::map<std::string, tl::Variant> &variables)
|
||||
{
|
||||
std::auto_ptr<ExpressionWrapper> expr (new ExpressionWrapper ());
|
||||
std::unique_ptr<ExpressionWrapper> expr (new ExpressionWrapper ());
|
||||
for (std::map<std::string, tl::Variant>::const_iterator v = variables.begin (); v != variables.end (); ++v) {
|
||||
expr->set_var (v->first, v->second);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -765,7 +765,7 @@ struct reader<gsi::StringType>
|
|||
void
|
||||
operator() (tl::Variant *out, gsi::SerialArgs *rr, const gsi::ArgType &, tl::Heap *heap)
|
||||
{
|
||||
std::auto_ptr<StringAdaptor> a ((StringAdaptor *) rr->read<void *>(*heap));
|
||||
std::unique_ptr<StringAdaptor> a ((StringAdaptor *) rr->read<void *>(*heap));
|
||||
if (!a.get ()) {
|
||||
*out = tl::Variant ();
|
||||
} else {
|
||||
|
|
@ -783,7 +783,7 @@ struct reader<gsi::VariantType>
|
|||
void
|
||||
operator() (tl::Variant *out, gsi::SerialArgs *rr, const gsi::ArgType &, tl::Heap *heap)
|
||||
{
|
||||
std::auto_ptr<VariantAdaptor> a ((VariantAdaptor *) rr->read<void *>(*heap));
|
||||
std::unique_ptr<VariantAdaptor> a ((VariantAdaptor *) rr->read<void *>(*heap));
|
||||
if (!a.get ()) {
|
||||
*out = tl::Variant ();
|
||||
} else {
|
||||
|
|
@ -801,7 +801,7 @@ struct reader<MapType>
|
|||
void
|
||||
operator() (tl::Variant *out, gsi::SerialArgs *rr, const gsi::ArgType &atype, tl::Heap *heap)
|
||||
{
|
||||
std::auto_ptr<MapAdaptor> a ((MapAdaptor *) rr->read<void *>(*heap));
|
||||
std::unique_ptr<MapAdaptor> a ((MapAdaptor *) rr->read<void *>(*heap));
|
||||
if (!a.get ()) {
|
||||
*out = tl::Variant ();
|
||||
} else {
|
||||
|
|
@ -822,7 +822,7 @@ struct reader<VectorType>
|
|||
void
|
||||
operator() (tl::Variant *out, gsi::SerialArgs *rr, const gsi::ArgType &atype, tl::Heap *heap)
|
||||
{
|
||||
std::auto_ptr<VectorAdaptor> a ((VectorAdaptor *) rr->read<void *>(*heap));
|
||||
std::unique_ptr<VectorAdaptor> a ((VectorAdaptor *) rr->read<void *>(*heap));
|
||||
if (!a.get ()) {
|
||||
*out = tl::Variant ();
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ AdaptorBase::~AdaptorBase ()
|
|||
|
||||
void AdaptorBase::tie_copies (AdaptorBase *target, tl::Heap &heap)
|
||||
{
|
||||
std::auto_ptr<AdaptorBase> t (target);
|
||||
std::unique_ptr<AdaptorBase> t (target);
|
||||
copy_to (target, heap);
|
||||
|
||||
// This object (which will be destroyed before this is responsible for copying back
|
||||
|
|
|
|||
|
|
@ -498,7 +498,7 @@ private:
|
|||
{
|
||||
check_data ();
|
||||
|
||||
std::auto_ptr<AdaptorBase> p (*(AdaptorBase **)mp_read);
|
||||
std::unique_ptr<AdaptorBase> p (*(AdaptorBase **)mp_read);
|
||||
mp_read += item_size<AdaptorBase *> ();
|
||||
tl_assert (p.get () != 0);
|
||||
|
||||
|
|
@ -514,7 +514,7 @@ private:
|
|||
|
||||
check_data ();
|
||||
|
||||
std::auto_ptr<AdaptorBase> p (*(AdaptorBase **)mp_read);
|
||||
std::unique_ptr<AdaptorBase> p (*(AdaptorBase **)mp_read);
|
||||
mp_read += item_size<AdaptorBase *> ();
|
||||
tl_assert (p.get () != 0);
|
||||
|
||||
|
|
@ -550,7 +550,7 @@ private:
|
|||
|
||||
check_data ();
|
||||
|
||||
std::auto_ptr<AdaptorBase> p (*(AdaptorBase **)mp_read);
|
||||
std::unique_ptr<AdaptorBase> p (*(AdaptorBase **)mp_read);
|
||||
mp_read += item_size<AdaptorBase *> ();
|
||||
|
||||
x_type *x = 0;
|
||||
|
|
@ -1399,7 +1399,7 @@ public:
|
|||
gsi::SerialArgs rr (serial_size ());
|
||||
tl_assert (v->serial_size () == serial_size ());
|
||||
|
||||
std::auto_ptr<VectorAdaptorIterator> i (create_iterator ());
|
||||
std::unique_ptr<VectorAdaptorIterator> i (create_iterator ());
|
||||
while (! i->at_end ()) {
|
||||
rr.reset ();
|
||||
i->get (rr, heap);
|
||||
|
|
@ -1672,7 +1672,7 @@ public:
|
|||
gsi::SerialArgs rr (serial_size ());
|
||||
tl_assert (v->serial_size () == serial_size ());
|
||||
|
||||
std::auto_ptr<MapAdaptorIterator> i (create_iterator ());
|
||||
std::unique_ptr<MapAdaptorIterator> i (create_iterator ());
|
||||
while (! i->at_end ()) {
|
||||
rr.reset ();
|
||||
i->get (rr, heap);
|
||||
|
|
@ -1963,7 +1963,7 @@ inline AdaptorBase *adaptor_factory<Tag, X>::get (const X &v)
|
|||
template <class X>
|
||||
inline void copy_to (AdaptorBase &a, X &x, tl::Heap &heap)
|
||||
{
|
||||
std::auto_ptr<AdaptorBase> t (adaptor_factory<typename gsi::type_traits<X &>::tag, X &>::get (x));
|
||||
std::unique_ptr<AdaptorBase> t (adaptor_factory<typename gsi::type_traits<X &>::tag, X &>::get (x));
|
||||
a.copy_to (t.get (), heap);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ int _force_link_f ()
|
|||
// ----------------------------------------------------------------
|
||||
// Implementation of A
|
||||
|
||||
static std::auto_ptr<A> a_inst;
|
||||
static std::unique_ptr<A> a_inst;
|
||||
static int a_count = 0;
|
||||
|
||||
void A::br ()
|
||||
|
|
@ -310,7 +310,7 @@ std::vector<int> C::m_v;
|
|||
// ----------------------------------------------------------------
|
||||
// Implementation of E
|
||||
|
||||
std::auto_ptr<E> E::e_inst;
|
||||
std::unique_ptr<E> E::e_inst;
|
||||
int E::e_count = 0;
|
||||
|
||||
E::E() : x(0)
|
||||
|
|
@ -373,7 +373,7 @@ int inst_count();
|
|||
// ----------------------------------------------------------------
|
||||
// Implementation of F
|
||||
|
||||
std::auto_ptr<F> F::f_inst;
|
||||
std::unique_ptr<F> F::f_inst;
|
||||
|
||||
const F &F::icref()
|
||||
{
|
||||
|
|
@ -414,8 +414,8 @@ F *F::inc()
|
|||
// ----------------------------------------------------------------
|
||||
// Implementation of X
|
||||
|
||||
std::auto_ptr<X> X::sp_a (new X ("X::a"));
|
||||
std::auto_ptr<X> X::sp_b (new X ("X::b"));
|
||||
std::unique_ptr<X> X::sp_a (new X ("X::a"));
|
||||
std::unique_ptr<X> X::sp_b (new X ("X::b"));
|
||||
|
||||
static X *make_x (const char *x)
|
||||
{
|
||||
|
|
@ -524,8 +524,8 @@ void X::set_si (int v)
|
|||
// ----------------------------------------------------------------
|
||||
// Implementation of Y
|
||||
|
||||
std::auto_ptr<Y> Y::sp_a (new Y ("Y::a"));
|
||||
std::auto_ptr<Y> Y::sp_b (new Y ("Y::b"));
|
||||
std::unique_ptr<Y> Y::sp_a (new Y ("Y::a"));
|
||||
std::unique_ptr<Y> Y::sp_b (new Y ("Y::b"));
|
||||
int Y::s_dyn_count = 0;
|
||||
|
||||
static Y *make_y (const char *x)
|
||||
|
|
|
|||
|
|
@ -980,7 +980,7 @@ struct E
|
|||
|
||||
private:
|
||||
int x;
|
||||
static std::auto_ptr<E> e_inst;
|
||||
static std::unique_ptr<E> e_inst;
|
||||
static int e_count;
|
||||
};
|
||||
|
||||
|
|
@ -996,7 +996,7 @@ struct F
|
|||
int get_x() const { return x; }
|
||||
|
||||
int x;
|
||||
static std::auto_ptr<F> f_inst;
|
||||
static std::unique_ptr<F> f_inst;
|
||||
};
|
||||
|
||||
struct G
|
||||
|
|
@ -1043,7 +1043,7 @@ protected:
|
|||
std::string m_s;
|
||||
|
||||
private:
|
||||
static std::auto_ptr<X> sp_a, sp_b;
|
||||
static std::unique_ptr<X> sp_a, sp_b;
|
||||
};
|
||||
|
||||
class Y
|
||||
|
|
@ -1072,7 +1072,7 @@ public:
|
|||
int i () const;
|
||||
|
||||
private:
|
||||
static std::auto_ptr<Y> sp_a, sp_b;
|
||||
static std::unique_ptr<Y> sp_a, sp_b;
|
||||
static int s_dyn_count;
|
||||
Y *mp_c;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -409,7 +409,7 @@ private:
|
|||
|
||||
static ImageRef *img_from_s (const std::string &s)
|
||||
{
|
||||
std::auto_ptr<ImageRef> img (new ImageRef ());
|
||||
std::unique_ptr<ImageRef> img (new ImageRef ());
|
||||
img->from_string (s.c_str ());
|
||||
return img.release ();
|
||||
}
|
||||
|
|
@ -419,7 +419,7 @@ static ImageRef *load_image (const std::string &path)
|
|||
tl::InputFile file (path);
|
||||
tl::InputStream stream (file);
|
||||
|
||||
std::auto_ptr<img::Object> read;
|
||||
std::unique_ptr<img::Object> read;
|
||||
read.reset (img::ImageStreamer::read (stream));
|
||||
// need to create a copy for now ...
|
||||
return new ImageRef (*read);
|
||||
|
|
|
|||
|
|
@ -1492,7 +1492,7 @@ Object::read_file ()
|
|||
|
||||
tl::InputFile file (m_filename);
|
||||
tl::InputStream stream (file);
|
||||
std::auto_ptr<img::Object> read;
|
||||
std::unique_ptr<img::Object> read;
|
||||
read.reset (img::ImageStreamer::read (stream));
|
||||
read->m_filename = m_filename;
|
||||
|
||||
|
|
|
|||
|
|
@ -224,7 +224,7 @@ string_to_pixels (img::Object *img, const std::string &s, size_t row, size_t w,
|
|||
img::Object *
|
||||
ImageProxy::get_image () const
|
||||
{
|
||||
std::auto_ptr<img::Object> img (new Object (std::max (size_t (1), m_width), std::max (size_t (1), m_height), m_matrix, m_color, ! m_byte_data.empty ()));
|
||||
std::unique_ptr<img::Object> img (new Object (std::max (size_t (1), m_width), std::max (size_t (1), m_height), m_matrix, m_color, ! m_byte_data.empty ()));
|
||||
img->set_min_value (m_min_value);
|
||||
img->set_max_value (m_max_value);
|
||||
img->set_data_mapping (m_data_mapping);
|
||||
|
|
|
|||
|
|
@ -61,7 +61,7 @@ TEST(1_FloatMono)
|
|||
img::ImageStreamer::write (stream, image);
|
||||
}
|
||||
|
||||
std::auto_ptr<img::Object> read;
|
||||
std::unique_ptr<img::Object> read;
|
||||
|
||||
{
|
||||
tl::InputFile file (path);
|
||||
|
|
@ -94,7 +94,7 @@ TEST(2_FloatMonoWithMask)
|
|||
img::ImageStreamer::write (stream, image);
|
||||
}
|
||||
|
||||
std::auto_ptr<img::Object> read;
|
||||
std::unique_ptr<img::Object> read;
|
||||
|
||||
{
|
||||
tl::InputFile file (path);
|
||||
|
|
@ -123,7 +123,7 @@ TEST(3_ByteMono)
|
|||
img::ImageStreamer::write (stream, image);
|
||||
}
|
||||
|
||||
std::auto_ptr<img::Object> read;
|
||||
std::unique_ptr<img::Object> read;
|
||||
|
||||
{
|
||||
tl::InputFile file (path);
|
||||
|
|
@ -156,7 +156,7 @@ TEST(4_ByteMonoWithMask)
|
|||
img::ImageStreamer::write (stream, image);
|
||||
}
|
||||
|
||||
std::auto_ptr<img::Object> read;
|
||||
std::unique_ptr<img::Object> read;
|
||||
|
||||
{
|
||||
tl::InputFile file (path);
|
||||
|
|
@ -185,7 +185,7 @@ TEST(5_FloatColor)
|
|||
img::ImageStreamer::write (stream, image);
|
||||
}
|
||||
|
||||
std::auto_ptr<img::Object> read;
|
||||
std::unique_ptr<img::Object> read;
|
||||
|
||||
{
|
||||
tl::InputFile file (path);
|
||||
|
|
@ -218,7 +218,7 @@ TEST(6_FloatColorWithMask)
|
|||
img::ImageStreamer::write (stream, image);
|
||||
}
|
||||
|
||||
std::auto_ptr<img::Object> read;
|
||||
std::unique_ptr<img::Object> read;
|
||||
|
||||
{
|
||||
tl::InputFile file (path);
|
||||
|
|
@ -247,7 +247,7 @@ TEST(7_ByteColor)
|
|||
img::ImageStreamer::write (stream, image);
|
||||
}
|
||||
|
||||
std::auto_ptr<img::Object> read;
|
||||
std::unique_ptr<img::Object> read;
|
||||
|
||||
{
|
||||
tl::InputFile file (path);
|
||||
|
|
@ -280,7 +280,7 @@ TEST(8_ByteColorWithMask)
|
|||
img::ImageStreamer::write (stream, image);
|
||||
}
|
||||
|
||||
std::auto_ptr<img::Object> read;
|
||||
std::unique_ptr<img::Object> read;
|
||||
|
||||
{
|
||||
tl::InputFile file (path);
|
||||
|
|
|
|||
|
|
@ -252,7 +252,7 @@ klayout_main_cont (int &argc, char **argv)
|
|||
}
|
||||
}
|
||||
|
||||
std::auto_ptr<lay::ApplicationBase> app;
|
||||
std::unique_ptr<lay::ApplicationBase> app;
|
||||
if (non_ui_mode) {
|
||||
app.reset (new lay::NonGuiApplication (argc, argv));
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -248,8 +248,8 @@ static std::string application_doc ()
|
|||
void
|
||||
LAY_PUBLIC make_application_decl (bool non_gui_mode)
|
||||
{
|
||||
static std::auto_ptr<Class<lay::GuiApplication> > gui_app_decl;
|
||||
static std::auto_ptr<Class<lay::NonGuiApplication> > non_gui_app_decl;
|
||||
static std::unique_ptr<Class<lay::GuiApplication> > gui_app_decl;
|
||||
static std::unique_ptr<Class<lay::NonGuiApplication> > non_gui_app_decl;
|
||||
|
||||
if (non_gui_mode) {
|
||||
|
||||
|
|
|
|||
|
|
@ -1033,7 +1033,7 @@ ApplicationBase::run ()
|
|||
|
||||
BEGIN_PROTECTED
|
||||
|
||||
std::auto_ptr<lym::Macro> macro (new lym::Macro ());
|
||||
std::unique_ptr<lym::Macro> macro (new lym::Macro ());
|
||||
macro->load_from (*m);
|
||||
macro->set_file_path (*m);
|
||||
if (macro->show_in_menu ()) {
|
||||
|
|
@ -1084,7 +1084,7 @@ ApplicationBase::run ()
|
|||
}
|
||||
|
||||
if (mw->current_view () != 0) {
|
||||
std::auto_ptr <rdb::Database> db (new rdb::Database ());
|
||||
std::unique_ptr <rdb::Database> db (new rdb::Database ());
|
||||
db->load (f->second.first);
|
||||
int rdb_index = mw->current_view ()->add_rdb (db.release ());
|
||||
mw->current_view ()->open_rdb_browser (rdb_index, mw->current_view ()->active_cellview_index ());
|
||||
|
|
|
|||
|
|
@ -187,7 +187,7 @@ LibraryController::sync_files ()
|
|||
|
||||
if (needs_load) {
|
||||
|
||||
std::auto_ptr<db::Library> lib (new db::Library ());
|
||||
std::unique_ptr<db::Library> lib (new db::Library ());
|
||||
lib->set_description (filename);
|
||||
if (! p->second.empty ()) {
|
||||
lib->set_technology (p->second);
|
||||
|
|
|
|||
|
|
@ -293,7 +293,7 @@ MacroController::drop_url (const std::string &path_or_url)
|
|||
}
|
||||
|
||||
// load and run macro
|
||||
std::auto_ptr<lym::Macro> macro (new lym::Macro ());
|
||||
std::unique_ptr<lym::Macro> macro (new lym::Macro ());
|
||||
macro->load_from (path);
|
||||
macro->set_file_path (path);
|
||||
|
||||
|
|
|
|||
|
|
@ -1271,7 +1271,7 @@ MacroEditorDialog::update_inspected ()
|
|||
variableList->set_inspector (0);
|
||||
} else {
|
||||
|
||||
std::auto_ptr<gsi::Inspector> ci (mp_current_interpreter->inspector (m_eval_context));
|
||||
std::unique_ptr<gsi::Inspector> ci (mp_current_interpreter->inspector (m_eval_context));
|
||||
variableListFrame->setVisible (ci.get () != 0);
|
||||
variableList->set_inspector (ci.release ());
|
||||
|
||||
|
|
@ -3263,7 +3263,7 @@ MacroEditorDialog::stack_element_double_clicked (QListWidgetItem *item)
|
|||
MacroEditorPage *
|
||||
MacroEditorDialog::create_page (lym::Macro *macro)
|
||||
{
|
||||
std::auto_ptr<MacroEditorPage> editor (new MacroEditorPage (this, &m_highlighters));
|
||||
std::unique_ptr<MacroEditorPage> editor (new MacroEditorPage (this, &m_highlighters));
|
||||
editor->set_ntab (m_ntab);
|
||||
editor->set_nindent (m_nindent);
|
||||
editor->set_font (m_font_family, m_font_size);
|
||||
|
|
|
|||
|
|
@ -51,7 +51,7 @@ public:
|
|||
}
|
||||
|
||||
private:
|
||||
std::auto_ptr<gsi::Inspector> mp_inspector;
|
||||
std::unique_ptr<gsi::Inspector> mp_inspector;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
@ -180,7 +180,7 @@ void MacroVariableView::expanded (QTreeWidgetItem *item)
|
|||
if (item->childCount () > 0) {
|
||||
PlaceholderItem *ph = dynamic_cast<PlaceholderItem *> (item->child (0));
|
||||
if (ph) {
|
||||
std::auto_ptr<QTreeWidgetItem> ph_taken (item->takeChild (0));
|
||||
std::unique_ptr<QTreeWidgetItem> ph_taken (item->takeChild (0));
|
||||
sync (item, ph->inspector (), true);
|
||||
}
|
||||
}
|
||||
|
|
@ -238,7 +238,7 @@ void MacroVariableView::sync_item (QTreeWidgetItem *parent, gsi::Inspector *insp
|
|||
|
||||
if (inspector->has_children (index)) {
|
||||
|
||||
std::auto_ptr<gsi::Inspector> ci (inspector->child_inspector (index));
|
||||
std::unique_ptr<gsi::Inspector> ci (inspector->child_inspector (index));
|
||||
update_value (item, inspector_description (ci.get ()), false);
|
||||
if (item->isExpanded ()) {
|
||||
sync (item, ci.get (), fresh);
|
||||
|
|
|
|||
|
|
@ -81,7 +81,7 @@ private:
|
|||
void sync_item (QTreeWidgetItem *parent, gsi::Inspector *inspector, const QString &key, size_t index, int pos, bool fresh);
|
||||
void sync (bool fresh);
|
||||
|
||||
std::auto_ptr<gsi::Inspector> mp_inspector;
|
||||
std::unique_ptr<gsi::Inspector> mp_inspector;
|
||||
bool m_show_all;
|
||||
};
|
||||
|
||||
|
|
|
|||
|
|
@ -720,7 +720,7 @@ private:
|
|||
lay::HelpDialog *mp_assistant;
|
||||
std::string m_current_session;
|
||||
std::string m_message;
|
||||
std::auto_ptr<QPrinter> mp_printer;
|
||||
std::unique_ptr<QPrinter> mp_printer;
|
||||
std::vector<QString> m_changed_files;
|
||||
|
||||
// the object manager (undo/redo mechanism and others)
|
||||
|
|
|
|||
|
|
@ -447,7 +447,7 @@ SaltDownloadManager::execute (lay::SaltManagerDialog *parent, lay::Salt &salt)
|
|||
return true;
|
||||
}
|
||||
|
||||
std::auto_ptr<lay::ConfirmationDialog> dialog (make_confirmation_dialog (parent, salt));
|
||||
std::unique_ptr<lay::ConfirmationDialog> dialog (make_confirmation_dialog (parent, salt));
|
||||
|
||||
dialog->setModal (true);
|
||||
dialog->show ();
|
||||
|
|
|
|||
|
|
@ -541,7 +541,7 @@ SaltGrain
|
|||
SaltGrain::from_url (const std::string &url_in)
|
||||
{
|
||||
std::string url = url_in;
|
||||
std::auto_ptr<tl::InputStream> stream (stream_from_url (url));
|
||||
std::unique_ptr<tl::InputStream> stream (stream_from_url (url));
|
||||
|
||||
SaltGrain g;
|
||||
g.load (*stream);
|
||||
|
|
|
|||
|
|
@ -23,6 +23,8 @@
|
|||
#ifndef HDR_laySaltGrainDetailsTextWidget
|
||||
#define HDR_laySaltGrainDetailsTextWidget
|
||||
|
||||
#include "laySaltGrain.h"
|
||||
|
||||
#include <QTextBrowser>
|
||||
#include <memory>
|
||||
|
||||
|
|
@ -57,7 +59,7 @@ private slots:
|
|||
void open_link (const QUrl &url);
|
||||
|
||||
private:
|
||||
std::auto_ptr<lay::SaltGrain> mp_grain;
|
||||
std::unique_ptr<lay::SaltGrain> mp_grain;
|
||||
|
||||
QString details_text ();
|
||||
};
|
||||
|
|
|
|||
|
|
@ -184,10 +184,10 @@ private:
|
|||
SaltGrainPropertiesDialog *mp_properties_dialog;
|
||||
tl::DeferredMethod<SaltManagerDialog> dm_update_models;
|
||||
int m_current_tab;
|
||||
std::auto_ptr<tl::InputStream> m_downloaded_grain_reader;
|
||||
std::auto_ptr<lay::SaltGrain> m_downloaded_grain, m_salt_mine_grain;
|
||||
std::unique_ptr<tl::InputStream> m_downloaded_grain_reader;
|
||||
std::unique_ptr<lay::SaltGrain> m_downloaded_grain, m_salt_mine_grain;
|
||||
SaltGrainDetailsTextWidget *mp_downloaded_target;
|
||||
std::auto_ptr<tl::InputStream> m_salt_mine_reader;
|
||||
std::unique_ptr<tl::InputStream> m_salt_mine_reader;
|
||||
|
||||
SaltGrain *current_grain ();
|
||||
std::vector<lay::SaltGrain *> current_grains ();
|
||||
|
|
|
|||
|
|
@ -981,7 +981,7 @@ BEGIN_PROTECTED
|
|||
return;
|
||||
}
|
||||
|
||||
std::auto_ptr<rdb::Database> rdb (new rdb::Database ());
|
||||
std::unique_ptr<rdb::Database> rdb (new rdb::Database ());
|
||||
|
||||
rdb->set_description (tl::to_string (QObject::tr ("Query results: ")) + m_last_query);
|
||||
rdb->set_name ("query_results");
|
||||
|
|
@ -1040,7 +1040,7 @@ BEGIN_PROTECTED
|
|||
query_to_model (model, lq, iq, std::numeric_limits<size_t>::max (), true);
|
||||
model.end_changes ();
|
||||
|
||||
std::auto_ptr <lay::LayoutHandle> handle (new lay::LayoutHandle (new db::Layout (), std::string ()));
|
||||
std::unique_ptr <lay::LayoutHandle> handle (new lay::LayoutHandle (new db::Layout (), std::string ()));
|
||||
handle->rename ("query_results");
|
||||
model.export_layout (handle->layout ());
|
||||
mp_view->add_layout (handle.release (), true);
|
||||
|
|
|
|||
|
|
@ -237,7 +237,7 @@ Session::restore (lay::MainWindow &mw)
|
|||
|
||||
for (unsigned int j = 0; j < vd.rdb_filenames.size (); ++j) {
|
||||
|
||||
std::auto_ptr<rdb::Database> rdb (new rdb::Database ());
|
||||
std::unique_ptr<rdb::Database> rdb (new rdb::Database ());
|
||||
|
||||
try {
|
||||
rdb->load (make_absolute (vd.rdb_filenames[j]));
|
||||
|
|
|
|||
|
|
@ -297,7 +297,7 @@ void signal_handler (int signo, siginfo_t *si, void *)
|
|||
lay::Version::name () + " " +
|
||||
lay::Version::version () + " (" + lay::Version::subversion () + ")\n";
|
||||
|
||||
std::auto_ptr<CrashMessage> msg;
|
||||
std::unique_ptr<CrashMessage> msg;
|
||||
|
||||
bool has_gui = s_sh_has_gui && lay::ApplicationBase::instance () && lay::ApplicationBase::instance ()->has_gui ();
|
||||
|
||||
|
|
|
|||
|
|
@ -358,7 +358,7 @@ TechSaveOptionsEditorPage::setup ()
|
|||
for (std::vector< std::pair<StreamWriterOptionsPage *, std::string> >::iterator page = m_pages.begin (); page != m_pages.end (); ++page) {
|
||||
if (page->first) {
|
||||
const db::FormatSpecificWriterOptions *specific_options = tech ()->save_layout_options ().get_options (page->second);
|
||||
std::auto_ptr<db::FormatSpecificWriterOptions> default_options;
|
||||
std::unique_ptr<db::FormatSpecificWriterOptions> default_options;
|
||||
if (! specific_options) {
|
||||
// In case there is no option object yet, create a first one for initialization
|
||||
default_options.reset (StreamWriterPluginDeclaration::plugin_for_format (page->second)->create_specific_options ());
|
||||
|
|
|
|||
|
|
@ -98,7 +98,7 @@ private:
|
|||
Ui::TechMacrosPage *mp_ui;
|
||||
std::string m_cat, m_cat_desc;
|
||||
std::vector<std::pair<QLabel *, QString> > m_original_labels;
|
||||
std::auto_ptr<lym::MacroCollection> mp_collection;
|
||||
std::unique_ptr<lym::MacroCollection> mp_collection;
|
||||
std::string m_current_path;
|
||||
|
||||
private slots:
|
||||
|
|
|
|||
|
|
@ -61,14 +61,14 @@ TEST (1)
|
|||
img_service->insert_image (img);
|
||||
}
|
||||
|
||||
std::auto_ptr<rdb::Database> rdb (new rdb::Database ());
|
||||
std::unique_ptr<rdb::Database> rdb (new rdb::Database ());
|
||||
rdb->load (tl::testsrc () + "/testdata/sessions/test.lyrdb");
|
||||
view->add_rdb (rdb.release ());
|
||||
|
||||
std::auto_ptr<db::LayoutToNetlist> l2ndb (db::LayoutToNetlist::create_from_file (tl::testsrc () + "/testdata/sessions/test.l2n"));
|
||||
std::unique_ptr<db::LayoutToNetlist> l2ndb (db::LayoutToNetlist::create_from_file (tl::testsrc () + "/testdata/sessions/test.l2n"));
|
||||
view->add_l2ndb (l2ndb.release ());
|
||||
|
||||
std::auto_ptr<db::LayoutToNetlist> lvsdb (db::LayoutToNetlist::create_from_file (tl::testsrc () + "/testdata/sessions/test.lvsdb"));
|
||||
std::unique_ptr<db::LayoutToNetlist> lvsdb (db::LayoutToNetlist::create_from_file (tl::testsrc () + "/testdata/sessions/test.lvsdb"));
|
||||
view->add_l2ndb (lvsdb.release ());
|
||||
|
||||
std::string lys_file = tmp_file ("test1.lys");
|
||||
|
|
|
|||
|
|
@ -281,7 +281,7 @@ LayoutHandle::update_save_options (db::SaveLayoutOptions &options)
|
|||
continue;
|
||||
}
|
||||
|
||||
std::auto_ptr<db::FormatSpecificWriterOptions> specific_options;
|
||||
std::unique_ptr<db::FormatSpecificWriterOptions> specific_options;
|
||||
if (options.get_options (decl->format_name ())) {
|
||||
specific_options.reset (options.get_options (decl->format_name ())->clone ());
|
||||
} else {
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ private slots:
|
|||
void cursor_position_changed ();
|
||||
|
||||
private:
|
||||
std::auto_ptr<lay::GenericSyntaxHighlighterAttributes> mp_hl_attributes, mp_hl_basic_attributes;
|
||||
std::unique_ptr<lay::GenericSyntaxHighlighterAttributes> mp_hl_attributes, mp_hl_basic_attributes;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -445,7 +445,7 @@ private:
|
|||
bool m_editable;
|
||||
db::PropertiesRepository *mp_prep;
|
||||
Ui::UserPropertiesForm *mp_ui;
|
||||
std::auto_ptr<lay::GenericSyntaxHighlighterAttributes> mp_hl_attributes, mp_hl_basic_attributes;
|
||||
std::unique_ptr<lay::GenericSyntaxHighlighterAttributes> mp_hl_attributes, mp_hl_basic_attributes;
|
||||
};
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -200,7 +200,7 @@ Dispatcher::write_config (const std::string &config_file)
|
|||
bool
|
||||
Dispatcher::read_config (const std::string &config_file)
|
||||
{
|
||||
std::auto_ptr<tl::XMLFileSource> file;
|
||||
std::unique_ptr<tl::XMLFileSource> file;
|
||||
|
||||
try {
|
||||
file.reset (new tl::XMLFileSource (config_file));
|
||||
|
|
|
|||
|
|
@ -90,7 +90,7 @@ Editables::~Editables ()
|
|||
void
|
||||
Editables::del (db::Transaction *transaction)
|
||||
{
|
||||
std::auto_ptr<db::Transaction> trans_holder (transaction ? transaction : new db::Transaction (manager (), tl::to_string (QObject::tr ("Delete"))));
|
||||
std::unique_ptr<db::Transaction> trans_holder (transaction ? transaction : new db::Transaction (manager (), tl::to_string (QObject::tr ("Delete"))));
|
||||
|
||||
if (has_selection ()) {
|
||||
|
||||
|
|
@ -168,7 +168,7 @@ Editables::selection_catch_bbox ()
|
|||
void
|
||||
Editables::transform (const db::DCplxTrans &tr, db::Transaction *transaction)
|
||||
{
|
||||
std::auto_ptr<db::Transaction> trans_holder (transaction ? transaction : new db::Transaction (manager (), tl::to_string (QObject::tr ("Transform"))));
|
||||
std::unique_ptr<db::Transaction> trans_holder (transaction ? transaction : new db::Transaction (manager (), tl::to_string (QObject::tr ("Transform"))));
|
||||
|
||||
if (has_selection ()) {
|
||||
|
||||
|
|
@ -594,7 +594,7 @@ Editables::move_transform (const db::DPoint &p, db::DFTrans t, lay::angle_constr
|
|||
void
|
||||
Editables::end_move (const db::DPoint &p, lay::angle_constraint_type ac, db::Transaction *transaction)
|
||||
{
|
||||
std::auto_ptr<db::Transaction> trans_holder (transaction ? transaction : new db::Transaction (manager (), tl::to_string (QObject::tr ("Move"))));
|
||||
std::unique_ptr<db::Transaction> trans_holder (transaction ? transaction : new db::Transaction (manager (), tl::to_string (QObject::tr ("Move"))));
|
||||
|
||||
if (m_any_move_operation) {
|
||||
|
||||
|
|
|
|||
|
|
@ -1633,7 +1633,7 @@ GenericSyntaxHighlighter::highlightBlock(const QString &text)
|
|||
int end_index = 0, last_index= -1;
|
||||
int attribute_id = 0, def_attribute_id = 0;
|
||||
|
||||
std::auto_ptr<SyntaxHighlighterUserData> user_data (new SyntaxHighlighterUserData ());
|
||||
std::unique_ptr<SyntaxHighlighterUserData> user_data (new SyntaxHighlighterUserData ());
|
||||
|
||||
while (std::max (0, index) < text.length ()) {
|
||||
|
||||
|
|
|
|||
|
|
@ -306,7 +306,7 @@ private:
|
|||
QColor m_text_color;
|
||||
tl::DeferredMethod<HierarchyControlPanel> m_do_update_content_dm;
|
||||
tl::DeferredMethod<HierarchyControlPanel> m_do_full_update_content_dm;
|
||||
std::auto_ptr<QStyle> mp_tree_style;
|
||||
std::unique_ptr<QStyle> mp_tree_style;
|
||||
|
||||
// locate the CellTreeItem in the tree corresponding to a partial path starting from p.
|
||||
CellTreeItem *find_child_item (cell_path_type::const_iterator start, cell_path_type::const_iterator end, CellTreeItem *p);
|
||||
|
|
|
|||
|
|
@ -336,7 +336,7 @@ public slots:
|
|||
private:
|
||||
QTabBar *mp_tab_bar;
|
||||
LCPTreeWidget *mp_layer_list;
|
||||
std::auto_ptr<QStyle> mp_ll_style;
|
||||
std::unique_ptr<QStyle> mp_ll_style;
|
||||
LayerTreeModel *mp_model;
|
||||
lay::LayoutView *mp_view;
|
||||
bool m_needs_update;
|
||||
|
|
|
|||
|
|
@ -5288,7 +5288,7 @@ LayoutView::paste_interactive ()
|
|||
{
|
||||
clear_selection ();
|
||||
|
||||
std::auto_ptr<db::Transaction> trans (new db::Transaction (manager (), tl::to_string (QObject::tr ("Paste and move"))));
|
||||
std::unique_ptr<db::Transaction> trans (new db::Transaction (manager (), tl::to_string (QObject::tr ("Paste and move"))));
|
||||
|
||||
{
|
||||
// let the receivers sort out who is pasting what ..
|
||||
|
|
|
|||
|
|
@ -250,7 +250,7 @@ private:
|
|||
QColor m_text_color;
|
||||
tl::DeferredMethod<LibrariesView> m_do_update_content_dm;
|
||||
tl::DeferredMethod<LibrariesView> m_do_full_update_content_dm;
|
||||
std::auto_ptr<QStyle> mp_tree_style;
|
||||
std::unique_ptr<QStyle> mp_tree_style;
|
||||
std::vector<tl::weak_ptr<db::Library> > m_libraries;
|
||||
|
||||
// event listener for changes in the cellview and layout
|
||||
|
|
|
|||
|
|
@ -247,7 +247,7 @@ MoveService::begin_move (db::Transaction *transaction, bool selected_after_move)
|
|||
return false;
|
||||
}
|
||||
|
||||
std::auto_ptr<db::Transaction> trans_holder (transaction);
|
||||
std::unique_ptr<db::Transaction> trans_holder (transaction);
|
||||
|
||||
bool drag_transient = ! selected_after_move;
|
||||
if (! mp_editables->has_selection ()) {
|
||||
|
|
@ -286,7 +286,7 @@ MoveService::begin_move (db::Transaction *transaction, bool selected_after_move)
|
|||
bool
|
||||
MoveService::handle_click (const db::DPoint &p, unsigned int buttons, bool drag_transient, db::Transaction *transaction)
|
||||
{
|
||||
std::auto_ptr<db::Transaction> trans_holder (transaction);
|
||||
std::unique_ptr<db::Transaction> trans_holder (transaction);
|
||||
|
||||
if (! m_dragging) {
|
||||
|
||||
|
|
|
|||
|
|
@ -71,7 +71,7 @@ private:
|
|||
double m_global_grid;
|
||||
db::DPoint m_shift;
|
||||
db::DPoint m_mouse_pos;
|
||||
std::auto_ptr<db::Transaction> mp_transaction;
|
||||
std::unique_ptr<db::Transaction> mp_transaction;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -377,14 +377,14 @@ private:
|
|||
db::LayoutToNetlist *mp_l2ndb;
|
||||
db::LayoutVsSchematic *mp_lvsdb;
|
||||
NetColorizer *mp_colorizer;
|
||||
std::auto_ptr<IndexedNetlistModel> mp_indexer;
|
||||
std::unique_ptr<IndexedNetlistModel> mp_indexer;
|
||||
mutable std::map<lay::color_t, QIcon> m_net_icon_per_color;
|
||||
mutable std::map<lay::color_t, QIcon> m_connection_icon_per_color;
|
||||
int m_object_column;
|
||||
int m_status_column;
|
||||
int m_first_column;
|
||||
int m_second_column;
|
||||
std::auto_ptr<NetlistModelItemData> mp_root;
|
||||
std::unique_ptr<NetlistModelItemData> mp_root;
|
||||
|
||||
RootItemData *root () const;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -1381,7 +1381,7 @@ NetlistBrowserPage::export_nets (const std::vector<const db::Net *> *nets)
|
|||
|
||||
const db::Cell &source_top = source_layout.cell (*source_layout.begin_top_down ());
|
||||
|
||||
std::auto_ptr<lay::NetExportDialog> dialog (new lay::NetExportDialog (this));
|
||||
std::unique_ptr<lay::NetExportDialog> dialog (new lay::NetExportDialog (this));
|
||||
if (dialog->exec_dialog (mp_plugin_root)) {
|
||||
|
||||
// NOTE: mp_view and database might get reset to 0 in create_layout
|
||||
|
|
|
|||
|
|
@ -93,7 +93,7 @@ private:
|
|||
|
||||
db::LayoutToNetlist *mp_l2ndb;
|
||||
db::LayoutVsSchematic *mp_lvsdb;
|
||||
std::auto_ptr<IndexedNetlistModel> mp_indexer;
|
||||
std::unique_ptr<IndexedNetlistModel> mp_indexer;
|
||||
mutable std::map<std::pair<const db::Circuit *, const db::Circuit *>, QModelIndex> m_circuits_to_index;
|
||||
int m_object_column;
|
||||
int m_status_column;
|
||||
|
|
|
|||
|
|
@ -123,7 +123,7 @@ private:
|
|||
QMutex m_initial_wait_lock;
|
||||
QWaitCondition m_initial_wait_cond;
|
||||
|
||||
std::auto_ptr<tl::SelfTimer> m_main_timer;
|
||||
std::unique_ptr<tl::SelfTimer> m_main_timer;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1265,7 +1265,7 @@ RedrawThreadWorker::draw_text_layer (bool drawing_context, db::cell_index_type c
|
|||
return;
|
||||
}
|
||||
|
||||
std::auto_ptr<lay::Bitmap> opt_bitmap;
|
||||
std::unique_ptr<lay::Bitmap> opt_bitmap;
|
||||
lay::Bitmap *vertex_bitmap = dynamic_cast<lay::Bitmap *> (vertex);
|
||||
if (m_text_lazy_rendering && vertex_bitmap) {
|
||||
opt_bitmap.reset (new lay::Bitmap (vertex_bitmap->width (), vertex_bitmap->height (), vertex_bitmap->resolution ()));
|
||||
|
|
|
|||
|
|
@ -244,7 +244,7 @@ private:
|
|||
std::vector<std::pair<unsigned int, lay::CanvasPlane *> > m_buffers;
|
||||
unsigned int m_test_count;
|
||||
tl::Clock m_clock;
|
||||
std::auto_ptr<lay::Renderer> mp_renderer;
|
||||
std::unique_ptr<lay::Renderer> mp_renderer;
|
||||
};
|
||||
|
||||
}
|
||||
|
|
|
|||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue