File tree Expand file tree Collapse file tree 2 files changed +1
-46
lines changed 
scala-2/chisel3/experimental/hierarchy 
scala/chisel3/experimental/hierarchy Expand file tree Collapse file tree 2 files changed +1
-46
lines changed Original file line number Diff line number Diff line change 1- package  chisel3 .experimental 
1+ package  chisel3 .experimental . hierarchy 
22
33/**  Classes or traits which will be used with the [[Definition ]] + [[Instance ]] api should be marked
44  * with the [[instantiable ]] annotation at the class/trait definition. 
Original file line number Diff line number Diff line change 11package  chisel3 .experimental 
22
33package  object  hierarchy  {
4- 
5-   /**  Classes or traits which will be used with the [[Definition ]] + [[Instance ]] api should be marked 
6-     * with the [[instantiable ]] annotation at the class/trait definition. 
7-     * 
8-     * @example  {{{ 
9-     * @instantiable 
10-     * class MyModule extends Module { 
11-     *   ... 
12-     * } 
13-     * 
14-     * val d = Definition(new MyModule) 
15-     * val i0 = Instance(d) 
16-     * val i1 = Instance(d) 
17-     * }}} 
18-     */  
19-   class  instantiable  extends  chisel3.internal.instantiable
20- 
21-   /**  Classes marked with [[instantiable ]] can have their vals marked with the [[public ]] annotation to 
22-     * enable accessing these values from a [[Definition ]] or [[Instance ]] of the class. 
23-     * 
24-     * Only vals of the the following types can be marked [[public ]]: 
25-     *   1. IsInstantiable 
26-     *   2. IsLookupable 
27-     *   3. Data 
28-     *   4. BaseModule 
29-     *   5. Iterable/Option containing a type that meets these requirements 
30-     *   6. Basic type like String, Int, BigInt etc. 
31-     * 
32-     * @example  {{{ 
33-     * @instantiable 
34-     * class MyModule extends Module { 
35-     *   @public val in = IO(Input(UInt(3.W))) 
36-     *   @public val out = IO(Output(UInt(3.W))) 
37-     *   .. 
38-     * } 
39-     * 
40-     * val d = Definition(new MyModule) 
41-     * val i0 = Instance(d) 
42-     * val i1 = Instance(d) 
43-     * 
44-     * i1.in := i0.out 
45-     * }}} 
46-     */  
47-   class  public  extends  chisel3.internal.public
48- 
494  type  Instance [P ] =  core.Instance [P ]
505  val  Instance  =  core.Instance 
516  type  Definition [P ] =  core.Definition [P ]
    
 
   
 
     
   
   
          
     
  
    
     
 
    
      
     
 
     
    You can’t perform that action at this time.
  
 
    
  
     
    
      
        
     
 
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments