Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9272947
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 18, 20262026-06-18T15:59:07+00:00 2026-06-18T15:59:07+00:00

I began to use templates a few weeks ago, and I’m having trouble using

  • 0

I began to use templates a few weeks ago, and I’m having trouble using it.
I got this error :

Freestyle/_gl/../_convection_selective/Definitions.h:153:9: error: ‘Node_handle’ in ‘Point_set {aka struct Kd_tree_patch > >*, My_point_property_map, CGAL::Search_traits > >, const double*, Construct_coord_iterator> > >}’ does not name a type

while compiling this code:

“Definitions.h”:

#include "Kd_tree_patch.h"
[...]
template <class SearchTraits, class Splitter_= CGAL::Sliding_midpoint<SearchTraits>, class UseExtendedNode = CGAL::Tag_true > class Kd_tree_patch;  //forward declaration

typedef Kd_tree_patch<Search_traits> Point_set;    
typedef Point_set::Node_handle Node_handle;

“Kd_tree_patch.h”:

template <class SearchTraits, class Splitter_=Sliding_midpoint<SearchTraits>, class UseExtendedNode = Tag_true >
class Kd_tree_patch {
[...]
typedef Kd_tree_node<SearchTraits, Splitter, UseExtendedNode > Node;
typedef typename Compact_container<Node>::iterator Node_handle;
};

Why Node_handle isn’t considered as a type yet ?

Thanks for your help.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-18T15:59:08+00:00Added an answer on June 18, 2026 at 3:59 pm

    You cannot forward declare nested types, which means that to be able to use the nested type Node_handle, the template Kd_tree_patch must be defined before the typedef. Once you fix that, you will also need to instruct the compiler that it is a type through the use of typename:

    typedef typename Point_set::Node_handle Node_handle;
    //      ^^^^^^^^
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Ever since ereg became depreciated, I began to use preg_match. Unfortunately in my code,
This is the instruction I use: BEGIN DBMS_SCHEDULER.RUN_JOB(25950); commit; END; And this is the
trying to use this route: from(activemq:profiles).aggregate(header(cheese)).batchSize(30).bean(ProfilesQueueService, saveContacts) Fails with: No signature of method: org.apache.camel.model.RouteType.aggregate()
I am using Puppet for automating configuration management across hosts. It can use erb
I am kind of startled, especially after reading this . I use template <class
I'm using GraniteDS Actionscript code generation templates that let's me take a Java object
I am trying to write a piece of code for fun using C++ templates.
I'm trying to learn the currently accepted features of c++11 and I'm having trouble
I am using the acm LaTeX template and I have trouble making my paper
I use freemarker with Spring. This is the way I configure my freemarker :

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.