| 网站首页 | 业界新闻 | 小组 | 威客 | 人才 | 下载频道 | 博客 | 代码贴 | 在线编程 | 编程论坛
欢迎加入我们,一同切磋技术
用户名:   
 
密 码:  
共有 566 人关注过本帖
标题:错那了,关于 template
只看楼主 加入收藏
rxgmoral
Rank: 1
等 级:新手上路
帖 子:45
专家分:0
注 册:2006-1-18
收藏
 问题点数:0 回复次数:3 
错那了,关于 template

错那了,关于 template

我是从C++Templates 里仿照写的
<<<<<<<H>>>>>>
#pragma once
export template <class T>
class rxg
{
public:
__declspec(dllexport) T Tem(T a);
};

报错如下:
warning C4237: 'export' keyword is not yet supported, but reserved for future use
error C2143: syntax error : missing ';' before ''template<''
error C4430: missing type specifier - int assumed. Note: C++ does not support default-int
Build log was saved at "Shared\Debug\BuildLog.htm"

谢谢:)

搜索更多相关主题的帖子: template 
2006-06-07 12:54
rxgmoral
Rank: 1
等 级:新手上路
帖 子:45
专家分:0
注 册:2006-1-18
收藏
得分:0 
顶................请大家看看
2006-06-08 14:40
Bekky
Rank: 3Rank: 3
等 级:新手上路
威 望:7
帖 子:354
专家分:0
注 册:2006-5-29
收藏
得分:0 
不知道,没试过.
__declspec,也支持模板吗??

我的编译环境为WinXp + VC 6.0 http://blog..cn/yobo
2006-06-08 16:46
rxgmoral
Rank: 1
等 级:新手上路
帖 子:45
专家分:0
注 册:2006-1-18
收藏
得分:0 
我是想写一个能导出的模板.......
谢谢:)

2006-06-09 09:57
快速回复:错那了,关于 template
数据加载中...
 
   



关于我们 | 广告合作 | 编程中国 | 清除Cookies | TOP | 手机版

编程中国 版权所有,并保留所有权利。
Powered by Discuz, Processed in 0.017493 second(s), 7 queries.
Copyright©2004-2024, BCCN.NET, All Rights Reserved